polyrex 1.1.6 → 1.1.7
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/lib/polyrex.rb +22 -1
- data.tar.gz.sig +1 -2
- 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: db66b0378eaea9abe96611c19c0070eabf8781fb
|
4
|
+
data.tar.gz: 0e656c947db8ba92901455d8717d99d525ba8d7c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ebe6d0a9cc16b5f78b28a4f4d3d792f905cb43f2480cde298f81e0f7c898da35741d0f7926e7d5d6e8a28f6275c178ee9877015a2f6e6786bf9f717c4f9b4d40
|
7
|
+
data.tar.gz: b628ba1cd69bdf7591bbcf9c77a1dd56a30ce0d814eeb2c7c48e37150034cda2128fea2e072377dd5e5484fb48fe5508453f1a87f6c71c9fa9f79a66142e9522
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/lib/polyrex.rb
CHANGED
@@ -718,10 +718,16 @@ xsl_buffer = '
|
|
718
718
|
a = PolyrexObjectMethods.new(schema).to_a
|
719
719
|
|
720
720
|
methodx = a.map do |class_name, methods|
|
721
|
+
|
721
722
|
class_name.downcase!
|
723
|
+
|
722
724
|
methods.map do |method_name|
|
725
|
+
|
723
726
|
xpath = %Q(@doc.root.element("//%s[summary/%s='\#\{val\}']")) % \
|
724
727
|
[class_name, method_name]
|
728
|
+
xpath2 = %Q(@doc.root.xpath("//%s[summary/%s='\#\{val\}']")) % \
|
729
|
+
[class_name, method_name]
|
730
|
+
|
725
731
|
"def find_by_#{class_name}_#{method_name}(val)
|
726
732
|
|
727
733
|
node = #{xpath}
|
@@ -732,7 +738,22 @@ xsl_buffer = '
|
|
732
738
|
nil
|
733
739
|
end
|
734
740
|
|
735
|
-
end
|
741
|
+
end
|
742
|
+
|
743
|
+
def find_all_by_#{class_name}_#{method_name}(val)
|
744
|
+
|
745
|
+
nodes = #{xpath2}
|
746
|
+
|
747
|
+
if nodes then
|
748
|
+
nodes.map do |node|
|
749
|
+
@objects['#{class_name}'].new(node, id: @id)
|
750
|
+
end
|
751
|
+
else
|
752
|
+
nil
|
753
|
+
end
|
754
|
+
|
755
|
+
end
|
756
|
+
"
|
736
757
|
end
|
737
758
|
end
|
738
759
|
|
data.tar.gz.sig
CHANGED
@@ -1,2 +1 @@
|
|
1
|
-
|
2
|
-
�qm���N�L�ApuRZ���,�ݷ�^��V��l*ܲ�l�<� ��R�#M�ަ��-ƻ+�7{�:/�:=m"���Qɏp5�r�= �H��;{*����9���i�^��5���u�'N�֤l��A��L��Z")[����i�A��t丹��z�q7S�}�Ɍd�@
|
1
|
+
/�ԫ-����b��$o���6֦"����`�/�z&Vd���v-P>������[*�.%e�� ������%@bDZ�!�Ǟ=kĐ�$��M5���[B�ۭ9�!x��<���ǡ_�CsI�n�(�T��uc��������?(��7����r��(�7k&��[dɘ*��#��B��١���0Bӏ�fMxc��U�l�[�EmDd_������Y����<��=a�~S��J���P$C��!:!
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: polyrex
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Robertson
|
@@ -31,7 +31,7 @@ cert_chain:
|
|
31
31
|
EUI+ncIuEEQSxIVKGeaQ49Dk10P2t0cX3DGyMlv7sreJohHxJfNKsjG/SAk0cks0
|
32
32
|
9+gffejS1ORTgQ==
|
33
33
|
-----END CERTIFICATE-----
|
34
|
-
date: 2016-11-
|
34
|
+
date: 2016-11-25 00:00:00.000000000 Z
|
35
35
|
dependencies:
|
36
36
|
- !ruby/object:Gem::Dependency
|
37
37
|
name: polyrex-schema
|
metadata.gz.sig
CHANGED
Binary file
|