wasabi 3.1.0 → 3.2.0

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.
@@ -1,30 +0,0 @@
1
- module Wasabi
2
- module XPathHelper
3
-
4
- NAMESPACES = {
5
- "xs" => "http://www.w3.org/2001/XMLSchema",
6
- "wsdl" => "http://schemas.xmlsoap.org/wsdl/",
7
- "soap11" => "http://schemas.xmlsoap.org/wsdl/soap/",
8
- "soap12" => "http://schemas.xmlsoap.org/wsdl/soap12/"
9
- }
10
-
11
- def xpath(*args)
12
- node, xpath = extract_xpath_args(args)
13
- node.xpath(xpath, NAMESPACES)
14
- end
15
-
16
- def at_xpath(*args)
17
- node, xpath = extract_xpath_args(args)
18
- node.at_xpath(xpath, NAMESPACES)
19
- end
20
-
21
- private
22
-
23
- def extract_xpath_args(args)
24
- xpath, target = args.reverse
25
- target ||= document if respond_to?(:document)
26
- [target, xpath]
27
- end
28
-
29
- end
30
- end