xmlregistry_objects 0.6.6 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/lib/xmlregistry_objects.rb +22 -1
- metadata +18 -18
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1e08026584bebc88eaae07633ece2f8ee13f96ae
|
4
|
+
data.tar.gz: 9f889c5413688467e481a1110577497a35ee41a3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8da96e60470b1215a37abe3696e8ae00e2ca9f7c90effc01d01bbd385cd445fc3716460d2237ec49893a7c97f9825a9f7cdc0b40b73f673991f7e45cdd9f0e5c
|
7
|
+
data.tar.gz: 9af6d1bb21138a40cfaf69368442a78dff5e1fd61ceab8024b301784ee3f98320d65ac212ac221a56b7e52d594037e8a499fd7ed3191aab043ef1b5543c443d5
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/lib/xmlregistry_objects.rb
CHANGED
@@ -69,7 +69,7 @@ class XMLRegistryObjects
|
|
69
69
|
a = reg.xpath("#{path}/*")
|
70
70
|
|
71
71
|
a.inject(base_methods) do |r, x|
|
72
|
-
|
72
|
+
|
73
73
|
methods_name = subkey = x.name
|
74
74
|
type = x.attributes[:class]
|
75
75
|
key = path + '/' + subkey
|
@@ -91,6 +91,27 @@ class XMLRegistryObjects
|
|
91
91
|
def define_methods()
|
92
92
|
@to_h.each.map {|k,v| "define_method :#{k.to_s}, ->{h[:#{k}]}"}.join("\n")
|
93
93
|
end
|
94
|
+
|
95
|
+
# to use this method the client is expect to fetch the
|
96
|
+
# hash object from the registry object e.g.
|
97
|
+
# xro = XMLRegistryObjects.new(reg,list)
|
98
|
+
# @h = xro.to_h
|
99
|
+
|
100
|
+
def define_methods2(obj=nil)
|
101
|
+
|
102
|
+
a = @to_h.each.map {|k,v| [k.to_s.to_sym, ->{@h[k.to_sym]} ] }
|
103
|
+
|
104
|
+
if obj then
|
105
|
+
|
106
|
+
a.each {|name, blk| obj.class.send(:define_method, name, blk) }
|
107
|
+
|
108
|
+
else
|
109
|
+
|
110
|
+
return a
|
111
|
+
|
112
|
+
end
|
113
|
+
|
114
|
+
end
|
94
115
|
|
95
116
|
private
|
96
117
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xmlregistry_objects
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Robertson
|
@@ -12,26 +12,26 @@ cert_chain:
|
|
12
12
|
-----BEGIN CERTIFICATE-----
|
13
13
|
MIIDljCCAn6gAwIBAgIBATANBgkqhkiG9w0BAQUFADBIMRIwEAYDVQQDDAlnZW1t
|
14
14
|
YXN0ZXIxHjAcBgoJkiaJk/IsZAEZFg5qYW1lc3JvYmVydHNvbjESMBAGCgmSJomT
|
15
|
-
|
15
|
+
8ixkARkWAmV1MB4XDTE1MDkwMzEyMzM1MVoXDTE2MDkwMjEyMzM1MVowSDESMBAG
|
16
16
|
A1UEAwwJZ2VtbWFzdGVyMR4wHAYKCZImiZPyLGQBGRYOamFtZXNyb2JlcnRzb24x
|
17
17
|
EjAQBgoJkiaJk/IsZAEZFgJldTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoC
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
18
|
+
ggEBALytp22hD7E+b3KRgMTa9wM8tptOpYVGPanhxw4vIggnQ3JG71mL8IYpjErd
|
19
|
+
/hGUe1XP165LrdaBAD9xFf9BawghGLyDuzSdaPDSpbv+6Z3xsjY8GTC4bqE3F5YF
|
20
|
+
ed/xaT8DaeuuipXqoc8d5mp+c5L2XV/XkTNiKN2CVzLr47SUvRgfC44/NObTG27f
|
21
|
+
nBjmtPeIIPeyiiMbe2XdiijDPfpk42TjYsEKHY+5Q5VOMFm2wZw1mM5J1YlFItuW
|
22
|
+
vtU8LiIpZipL5kKT9FtUI2QFl0FMzsAoNPj8SpMTLLwjltJYooGRlpDVQBeLU25X
|
23
|
+
ybRpgIT7U/Evfk0xH4T/9+SLgJkCAwEAAaOBijCBhzAJBgNVHRMEAjAAMAsGA1Ud
|
24
|
+
DwQEAwIEsDAdBgNVHQ4EFgQU4+siQoVQ5qLU0J6Ndv3kzJ1lHFQwJgYDVR0RBB8w
|
25
25
|
HYEbZ2VtbWFzdGVyQGphbWVzcm9iZXJ0c29uLmV1MCYGA1UdEgQfMB2BG2dlbW1h
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
26
|
+
c3RlckBqYW1lc3JvYmVydHNvbi5ldTANBgkqhkiG9w0BAQUFAAOCAQEAT1NZWx3J
|
27
|
+
NNNOLRvx7/7LvpUOXLJq8SahlltoIJ8cCs3czhm4Ko21figVZPI5Uwtio4leaKNh
|
28
|
+
TanuC4LEzyzfBmfOIm2WmFuca5KpWmPCejYduXuL+vurOp+2/kUw366+wybwfJZ0
|
29
|
+
rvCj3WHF2uYG2FqK4k165mAcuXHtIbF7d97dEtrnd1n5geH1qUS863QfFKToBAx0
|
30
|
+
XvbgNbCcqf6JF97oJEiNw1dykfNTAfv0h1JjD9846HeXefNc5/XYyRzvUjHF9j85
|
31
|
+
BpU5TkIjxOcipB/2bKv68UjAwozv1G2sRg9dV99DUJZMcHKUees9fIht8adwrVWo
|
32
|
+
wrwWTUFBC2xYMA==
|
33
33
|
-----END CERTIFICATE-----
|
34
|
-
date: 2015-
|
34
|
+
date: 2015-09-03 00:00:00.000000000 Z
|
35
35
|
dependencies:
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: dws-registry
|
@@ -100,7 +100,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
100
100
|
version: '0'
|
101
101
|
requirements: []
|
102
102
|
rubyforge_project:
|
103
|
-
rubygems_version: 2.4.
|
103
|
+
rubygems_version: 2.4.8
|
104
104
|
signing_key:
|
105
105
|
specification_version: 4
|
106
106
|
summary: Query the registry using objects built dynamically from a string which maps
|
metadata.gz.sig
CHANGED
Binary file
|