xml-registry 0.2.2 → 0.2.3
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 +1 -3
- data/lib/xml-registry.rb +5 -9
- data.tar.gz.sig +0 -0
- metadata +1 -1
- 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: 14f2ebebb08879ad4723797e88e9e0f076796511
|
4
|
+
data.tar.gz: 04f5cb77e74192564151d908cf20ec2cd155aa64
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 798108ab93c4ee2c8a2f0571dfdeff6471021b6f9b07594847a2096dbd1bb2034cd7e96b165abf6325f5abe9adba0cc92fda4ca1fb2831332c3c6cfda05367e9
|
7
|
+
data.tar.gz: a56e8a16812f1133839437d8b86927af17b8c086da107b7bd7536267b7939f27c27bf4eaf0129e3bb93a2d2f85aed2853aaca5d279c71902ed0413c2e5d2bd3c
|
checksums.yaml.gz.sig
CHANGED
@@ -1,3 +1 @@
|
|
1
|
-
}
|
2
|
-
Wk�Ŷ6�S������,F�\��3�������o�$m��`
|
3
|
-
O�w��5�L~O=��!W���ZF�W�$���R���R���X�R�6�L�Db��:���X��*���k����6i���Z�y�-�.8�%6w�v��E�-VI��)�a�)J��mO.�UM�((iZi��˅�N}t��"
|
1
|
+
`���jim .�Qq�֕sB��}�wN���� M�>����� Q:��R��}؆ F�c�c�tGjr��#Z��۲)���=�D�-@�p�%����/���j �S���{Qm5cg�j��;����n�Ht�1��8t�Q$��D
|
data/lib/xml-registry.rb
CHANGED
@@ -43,8 +43,8 @@ class XMLRegistry
|
|
43
43
|
add_value(path, value)
|
44
44
|
end
|
45
45
|
|
46
|
-
def
|
47
|
-
self.set_key
|
46
|
+
def []=(path, val)
|
47
|
+
self.set_key(path, val)
|
48
48
|
end
|
49
49
|
|
50
50
|
# get the key value by passing the path
|
@@ -57,10 +57,6 @@ class XMLRegistry
|
|
57
57
|
raise ("xml-registry: key %s not found" % path) unless key
|
58
58
|
key
|
59
59
|
end
|
60
|
-
|
61
|
-
def key[](path)
|
62
|
-
self.doc.root.element path
|
63
|
-
end
|
64
60
|
|
65
61
|
# get several keys using a Rexle XPath
|
66
62
|
# example: get_key('//funday') #=> [<funday>tuesday</funday>,<funday>friday</funday>]
|
@@ -68,11 +64,11 @@ class XMLRegistry
|
|
68
64
|
# returns an array of 0 or more Rexle elements
|
69
65
|
#
|
70
66
|
def get_keys(path)
|
71
|
-
@doc.root.xpath
|
67
|
+
@doc.root.xpath(path)
|
72
68
|
end
|
73
69
|
|
74
|
-
def
|
75
|
-
|
70
|
+
def [](path)
|
71
|
+
@doc.root.element path
|
76
72
|
end
|
77
73
|
|
78
74
|
# delete the key at the specified path
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
metadata.gz.sig
CHANGED
Binary file
|