system_navigation 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/VERSION +1 -1
- data/lib/system_navigation.rb +14 -0
- metadata +5 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a48e53dc7c6df86afb90efe820685217ced11818
|
4
|
+
data.tar.gz: 2bd4a1931429371505434da30f5bd7436e17b5e6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 90a0145f20a1b2ae313254b75d614f296a4db464b8674d4d7c3e708182ab718282e3350d433413cc4a3dd2b9ada4ebcb9f83a77dbcc04edf6eaa54fdc1992c54
|
7
|
+
data.tar.gz: 29a87e3bd536f535b02512e5dceae8b7c32bc2beb5831130aeb4f7b9a84e3e4c9824e3f02d92ea21d7ec9233c9d3e6aa79bee8638116c72399667803e785cb48
|
data/CHANGELOG.md
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.1
|
data/lib/system_navigation.rb
CHANGED
@@ -440,4 +440,18 @@ class SystemNavigation
|
|
440
440
|
klassmod.all_messages.as_array
|
441
441
|
end.uniq
|
442
442
|
end
|
443
|
+
|
444
|
+
##
|
445
|
+
# Get all methods (public, private, protected) that are defined on +behavior+.
|
446
|
+
#
|
447
|
+
# @since 0.2.1
|
448
|
+
# @example
|
449
|
+
# sn.all_methods_in_behavior(System)
|
450
|
+
# #=> {:public => {:instance => [...], :singleton => [...]}, ...}
|
451
|
+
#
|
452
|
+
# @param behavior [Module, Class] where to read methods from
|
453
|
+
# @return [Hash] a hash with UnboundMethods, divided into groups and scopes
|
454
|
+
def all_methods_in_behavior(behavior)
|
455
|
+
behavior.own_methods.to_h
|
456
|
+
end
|
443
457
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: system_navigation
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kyrylo Silin
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-06-
|
11
|
+
date: 2015-06-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: fast_method_source
|
@@ -66,7 +66,8 @@ dependencies:
|
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0.10'
|
69
|
-
description:
|
69
|
+
description: A library that provides additional introspection capabilities for Ruby
|
70
|
+
programs (allows various queries on methods and classes)
|
70
71
|
email: silin@kyrylo.org
|
71
72
|
executables: []
|
72
73
|
extensions: []
|
@@ -112,6 +113,6 @@ rubyforge_project:
|
|
112
113
|
rubygems_version: 2.4.5
|
113
114
|
signing_key:
|
114
115
|
specification_version: 4
|
115
|
-
summary:
|
116
|
+
summary: A library that provides additional introspection capabilities for Ruby programs
|
116
117
|
test_files: []
|
117
118
|
has_rdoc:
|