rexle-xpath-parser 0.1.5 → 0.1.6
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
- checksums.yaml.gz.sig +2 -2
- data.tar.gz.sig +0 -0
- data/lib/rexle-xpath-parser.rb +6 -4
- metadata +2 -2
- 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: 23e33280e27491cb437772dd4e5671209fb7bc19
|
|
4
|
+
data.tar.gz: 1272a975e382710683b156ada42e53a7ff76d716
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: cf6556c576522a09e4ce043c1569706ac436166f66145bcb04de4167586f37dfa841e8dc7f609e032055151b330dcdf64d3f24666a179a6143d18495c71d4018
|
|
7
|
+
data.tar.gz: 2fb4e472b99dbf0fd313e74dff7eed44bda746d77bf83ef6bcf35f3ebe98f872b3bc79a664b3005b06a173b55fd194d586a40c69a0737d0d395c9c37cc9e79ec
|
checksums.yaml.gz.sig
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
�
|
|
2
|
-
|
|
1
|
+
;���t�>�Vޘ�`r�zʺ�`��D�i�˟�F������k��/aZ� �Q�)E��~�<��w}�E�5ҁ�ht��!�_VW�Eɭ��U�`M ��:I�`-�qx���i�80�{�y�%�v7�?'�2T�K����*���4, m�<�2���LfDE�38M��ڬ���u
|
|
2
|
+
�G'9Pdn���9ڑhg���w��{�)B�{�K� ˸B}����'���;��Q����(�t�����2��|�/�,��+�Ĝ
|
data.tar.gz.sig
CHANGED
|
Binary file
|
data/lib/rexle-xpath-parser.rb
CHANGED
|
@@ -25,8 +25,10 @@ class RexleXPathParser
|
|
|
25
25
|
def functionalise(a)
|
|
26
26
|
|
|
27
27
|
a.inject([]) do |r,x|
|
|
28
|
-
|
|
29
|
-
if x =~
|
|
28
|
+
|
|
29
|
+
if x =~ /@[\w\/]+/ then
|
|
30
|
+
r << [[:attribute, x[/@(\w+)/,1]]]
|
|
31
|
+
elsif x =~ /[\w\/]+\[/
|
|
30
32
|
|
|
31
33
|
epath, predicate, remainder = x.match(/^([^\[]+)\[([^\]]+)\](.*)/).captures
|
|
32
34
|
|
|
@@ -41,7 +43,7 @@ class RexleXPathParser
|
|
|
41
43
|
[:predicate, RexleXPathParser.new(predicate).to_a] + r
|
|
42
44
|
|
|
43
45
|
elsif x =~ /=/
|
|
44
|
-
r[-1] << [:
|
|
46
|
+
r[-1] << [:value, :==, x[/=(.*)/,1].sub(/^["'](.*)["']$/,'\1')]
|
|
45
47
|
elsif x =~ /\|/
|
|
46
48
|
r << [:union]
|
|
47
49
|
elsif x =~ /\w+\(/
|
|
@@ -135,7 +137,7 @@ class RexleXPathParser
|
|
|
135
137
|
a2
|
|
136
138
|
|
|
137
139
|
else
|
|
138
|
-
token = s.slice!(/^[
|
|
140
|
+
token = s.slice!(/^[@?\w\/]+/)
|
|
139
141
|
a << token
|
|
140
142
|
remainder = s
|
|
141
143
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: rexle-xpath-parser
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.6
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- James Robertson
|
|
@@ -31,7 +31,7 @@ cert_chain:
|
|
|
31
31
|
adFNS7+S3VVpQqBQ7hIMoNW5ldGHINll6Z0dbjsCO8OFGOkrnzt9ovLffOXuQHpT
|
|
32
32
|
Gpk2If0KQMuV2Q==
|
|
33
33
|
-----END CERTIFICATE-----
|
|
34
|
-
date: 2016-05-
|
|
34
|
+
date: 2016-05-08 00:00:00.000000000 Z
|
|
35
35
|
dependencies: []
|
|
36
36
|
description:
|
|
37
37
|
email: james@r0bertson.co.uk
|
metadata.gz.sig
CHANGED
|
Binary file
|