soap4r_es 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/bin/wsdl2ruby.rb +140 -0
- data/bin/wsdl2ruby_rails.rb +140 -0
- data/bin/xsd2ruby.rb +92 -0
- data/lib/soap/attachment.rb +109 -0
- data/lib/soap/attrproxy.rb +35 -0
- data/lib/soap/baseData.rb +1095 -0
- data/lib/soap/element.rb +278 -0
- data/lib/soap/encodingstyle/aspDotNetHandler.rb +208 -0
- data/lib/soap/encodingstyle/handler.rb +121 -0
- data/lib/soap/encodingstyle/literalHandler.rb +196 -0
- data/lib/soap/encodingstyle/soapHandler.rb +560 -0
- data/lib/soap/filter/filterchain.rb +52 -0
- data/lib/soap/filter/handler.rb +32 -0
- data/lib/soap/filter/streamhandler.rb +30 -0
- data/lib/soap/filter.rb +14 -0
- data/lib/soap/generator.rb +299 -0
- data/lib/soap/header/handler.rb +64 -0
- data/lib/soap/header/handlerset.rb +78 -0
- data/lib/soap/header/mappinghandler.rb +48 -0
- data/lib/soap/header/simplehandler.rb +45 -0
- data/lib/soap/httpconfigloader.rb +140 -0
- data/lib/soap/mapping/encodedregistry.rb +541 -0
- data/lib/soap/mapping/factory.rb +389 -0
- data/lib/soap/mapping/literalregistry.rb +392 -0
- data/lib/soap/mapping/mapping.rb +577 -0
- data/lib/soap/mapping/registry.rb +297 -0
- data/lib/soap/mapping/rubytypeFactory.rb +446 -0
- data/lib/soap/mapping/schemadefinition.rb +171 -0
- data/lib/soap/mapping/typeMap.rb +107 -0
- data/lib/soap/mapping/wsdlencodedregistry.rb +212 -0
- data/lib/soap/mapping/wsdlliteralregistry.rb +249 -0
- data/lib/soap/mapping.rb +13 -0
- data/lib/soap/marshal.rb +60 -0
- data/lib/soap/mimemessage.rb +243 -0
- data/lib/soap/nestedexception.rb +43 -0
- data/lib/soap/netHttpClient.rb +242 -0
- data/lib/soap/ns.rb +39 -0
- data/lib/soap/parser.rb +253 -0
- data/lib/soap/processor.rb +67 -0
- data/lib/soap/property.rb +330 -0
- data/lib/soap/proxy.rb +15 -0
- data/lib/soap/rpc/cgistub.rb +249 -0
- data/lib/soap/rpc/driver.rb +222 -0
- data/lib/soap/rpc/element.rb +375 -0
- data/lib/soap/rpc/httpserver.rb +144 -0
- data/lib/soap/rpc/methodDef.rb +69 -0
- data/lib/soap/rpc/proxy.rb +573 -0
- data/lib/soap/rpc/router.rb +672 -0
- data/lib/soap/rpc/rpc.rb +26 -0
- data/lib/soap/rpc/soaplet.rb +201 -0
- data/lib/soap/rpc/standaloneServer.rb +44 -0
- data/lib/soap/soap.rb +163 -0
- data/lib/soap/streamHandler.rb +302 -0
- data/lib/soap/version.rb +12 -0
- data/lib/soap/wsdlDriver.rb +165 -0
- data/lib/wsdl/binding.rb +66 -0
- data/lib/wsdl/data.rb +65 -0
- data/lib/wsdl/definitions.rb +237 -0
- data/lib/wsdl/documentation.rb +33 -0
- data/lib/wsdl/import.rb +81 -0
- data/lib/wsdl/importer.rb +39 -0
- data/lib/wsdl/info.rb +51 -0
- data/lib/wsdl/message.rb +55 -0
- data/lib/wsdl/operation.rb +152 -0
- data/lib/wsdl/operationBinding.rb +241 -0
- data/lib/wsdl/param.rb +94 -0
- data/lib/wsdl/parser.rb +180 -0
- data/lib/wsdl/part.rb +53 -0
- data/lib/wsdl/port.rb +67 -0
- data/lib/wsdl/portType.rb +76 -0
- data/lib/wsdl/service.rb +62 -0
- data/lib/wsdl/soap/address.rb +41 -0
- data/lib/wsdl/soap/binding.rb +50 -0
- data/lib/wsdl/soap/body.rb +59 -0
- data/lib/wsdl/soap/cgiStubCreator.rb +93 -0
- data/lib/wsdl/soap/classDefCreator.rb +529 -0
- data/lib/wsdl/soap/classDefCreatorSupport.rb +242 -0
- data/lib/wsdl/soap/classNameCreator.rb +57 -0
- data/lib/wsdl/soap/clientSkeltonCreator.rb +107 -0
- data/lib/wsdl/soap/complexType.rb +174 -0
- data/lib/wsdl/soap/data.rb +43 -0
- data/lib/wsdl/soap/definitions.rb +201 -0
- data/lib/wsdl/soap/driverCreator.rb +121 -0
- data/lib/wsdl/soap/element.rb +34 -0
- data/lib/wsdl/soap/encodedMappingRegistryCreator.rb +74 -0
- data/lib/wsdl/soap/fault.rb +57 -0
- data/lib/wsdl/soap/header.rb +87 -0
- data/lib/wsdl/soap/headerfault.rb +57 -0
- data/lib/wsdl/soap/literalMappingRegistryCreator.rb +116 -0
- data/lib/wsdl/soap/mappingRegistryCreator.rb +59 -0
- data/lib/wsdl/soap/mappingRegistryCreatorSupport.rb +380 -0
- data/lib/wsdl/soap/methodDefCreator.rb +200 -0
- data/lib/wsdl/soap/operation.rb +113 -0
- data/lib/wsdl/soap/servantSkeltonCreator.rb +92 -0
- data/lib/wsdl/soap/servletStubCreator.rb +105 -0
- data/lib/wsdl/soap/standaloneServerStubCreator.rb +101 -0
- data/lib/wsdl/soap/wsdl2ruby.rb +249 -0
- data/lib/wsdl/types.rb +45 -0
- data/lib/wsdl/wsdl.rb +25 -0
- data/lib/wsdl/xmlSchema/all.rb +25 -0
- data/lib/wsdl/xmlSchema/annotation.rb +35 -0
- data/lib/wsdl/xmlSchema/any.rb +62 -0
- data/lib/wsdl/xmlSchema/anyAttribute.rb +49 -0
- data/lib/wsdl/xmlSchema/attribute.rb +105 -0
- data/lib/wsdl/xmlSchema/attributeGroup.rb +69 -0
- data/lib/wsdl/xmlSchema/choice.rb +59 -0
- data/lib/wsdl/xmlSchema/complexContent.rb +98 -0
- data/lib/wsdl/xmlSchema/complexExtension.rb +120 -0
- data/lib/wsdl/xmlSchema/complexRestriction.rb +105 -0
- data/lib/wsdl/xmlSchema/complexType.rb +194 -0
- data/lib/wsdl/xmlSchema/content.rb +96 -0
- data/lib/wsdl/xmlSchema/data.rb +117 -0
- data/lib/wsdl/xmlSchema/element.rb +154 -0
- data/lib/wsdl/xmlSchema/enumeration.rb +37 -0
- data/lib/wsdl/xmlSchema/fractiondigits.rb +38 -0
- data/lib/wsdl/xmlSchema/group.rb +101 -0
- data/lib/wsdl/xmlSchema/import.rb +53 -0
- data/lib/wsdl/xmlSchema/importHandler.rb +45 -0
- data/lib/wsdl/xmlSchema/importer.rb +103 -0
- data/lib/wsdl/xmlSchema/include.rb +48 -0
- data/lib/wsdl/xmlSchema/length.rb +38 -0
- data/lib/wsdl/xmlSchema/list.rb +49 -0
- data/lib/wsdl/xmlSchema/maxexclusive.rb +38 -0
- data/lib/wsdl/xmlSchema/maxinclusive.rb +38 -0
- data/lib/wsdl/xmlSchema/maxlength.rb +38 -0
- data/lib/wsdl/xmlSchema/minexclusive.rb +38 -0
- data/lib/wsdl/xmlSchema/mininclusive.rb +38 -0
- data/lib/wsdl/xmlSchema/minlength.rb +38 -0
- data/lib/wsdl/xmlSchema/parser.rb +168 -0
- data/lib/wsdl/xmlSchema/pattern.rb +37 -0
- data/lib/wsdl/xmlSchema/ref.rb +34 -0
- data/lib/wsdl/xmlSchema/schema.rb +179 -0
- data/lib/wsdl/xmlSchema/sequence.rb +55 -0
- data/lib/wsdl/xmlSchema/simpleContent.rb +70 -0
- data/lib/wsdl/xmlSchema/simpleExtension.rb +63 -0
- data/lib/wsdl/xmlSchema/simpleRestriction.rb +133 -0
- data/lib/wsdl/xmlSchema/simpleType.rb +88 -0
- data/lib/wsdl/xmlSchema/totaldigits.rb +38 -0
- data/lib/wsdl/xmlSchema/union.rb +36 -0
- data/lib/wsdl/xmlSchema/unique.rb +35 -0
- data/lib/wsdl/xmlSchema/whitespace.rb +38 -0
- data/lib/wsdl/xmlSchema/xsd2ruby.rb +177 -0
- data/lib/xsd/charset.rb +190 -0
- data/lib/xsd/codegen/classdef.rb +230 -0
- data/lib/xsd/codegen/commentdef.rb +35 -0
- data/lib/xsd/codegen/gensupport.rb +277 -0
- data/lib/xsd/codegen/methoddef.rb +71 -0
- data/lib/xsd/codegen/moduledef.rb +209 -0
- data/lib/xsd/codegen.rb +13 -0
- data/lib/xsd/datatypes.rb +1465 -0
- data/lib/xsd/datatypes1999.rb +21 -0
- data/lib/xsd/iconvcharset.rb +33 -0
- data/lib/xsd/mapping.rb +69 -0
- data/lib/xsd/namedelements.rb +133 -0
- data/lib/xsd/ns.rb +183 -0
- data/lib/xsd/qname.rb +80 -0
- data/lib/xsd/xmlparser/libxmlparser.rb +136 -0
- data/lib/xsd/xmlparser/nokogiriparser.rb +63 -0
- data/lib/xsd/xmlparser/ogaparser.rb +53 -0
- data/lib/xsd/xmlparser/oxparser.rb +97 -0
- data/lib/xsd/xmlparser/parser.rb +101 -0
- data/lib/xsd/xmlparser/rexmlparser.rb +54 -0
- data/lib/xsd/xmlparser.rb +81 -0
- metadata +240 -0
@@ -0,0 +1,53 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
# OgaParser XML parser library.
|
3
|
+
# Copyright (C) 2015 Laurence A. Lee <rubyjedi@gmail.com>.
|
4
|
+
|
5
|
+
# This program is copyrighted free software by Laurence A. Lee. You can
|
6
|
+
# redistribute it and/or modify it under the same terms of Ruby's license;
|
7
|
+
# either the dual license version in 2003, or any later version.
|
8
|
+
|
9
|
+
require 'oga'
|
10
|
+
|
11
|
+
|
12
|
+
module XSD
|
13
|
+
module XMLParser
|
14
|
+
|
15
|
+
class OgaParser < XSD::XMLParser::Parser
|
16
|
+
|
17
|
+
def do_parse(string_or_readable)
|
18
|
+
$stderr.puts "XSD::XMLParser::OgaParser.do_parse" if $DEBUG
|
19
|
+
Oga.sax_parse_xml(self, string_or_readable)
|
20
|
+
end
|
21
|
+
|
22
|
+
|
23
|
+
def on_element(namespace, name, attrs)
|
24
|
+
start_element(node_name(namespace, name), attrs)
|
25
|
+
end
|
26
|
+
|
27
|
+
def after_element(namespace, name)
|
28
|
+
end_element(node_name(namespace, name))
|
29
|
+
end
|
30
|
+
|
31
|
+
def on_text(t)
|
32
|
+
characters(t)
|
33
|
+
end
|
34
|
+
|
35
|
+
alias_method :on_cdata, :on_text
|
36
|
+
alias_method :on_comment, :on_text
|
37
|
+
|
38
|
+
def on_xml_decl(attr_hash)
|
39
|
+
send :xmldecl_encoding=,attr_hash['encoding']
|
40
|
+
end
|
41
|
+
|
42
|
+
private
|
43
|
+
|
44
|
+
def node_name(namespace, name)
|
45
|
+
namespace ? "#{namespace}:#{name}" : name.to_s
|
46
|
+
end
|
47
|
+
|
48
|
+
add_factory(self)
|
49
|
+
|
50
|
+
end
|
51
|
+
|
52
|
+
end
|
53
|
+
end
|
@@ -0,0 +1,97 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
# XSD4R - OXParser XML parser library.
|
3
|
+
# Copyright (C) 2015 Laurence A. Lee <rubyjedi@gmail.com>.
|
4
|
+
|
5
|
+
# This program is copyrighted free software by Laurence A. Lee. You can
|
6
|
+
# redistribute it and/or modify it under the same terms of Ruby's license;
|
7
|
+
# either the dual license version in 2003, or any later version.
|
8
|
+
|
9
|
+
require 'ox'
|
10
|
+
|
11
|
+
module XSD
|
12
|
+
module XMLParser
|
13
|
+
|
14
|
+
class OxParser < XSD::XMLParser::Parser
|
15
|
+
def do_parse(string_or_readable)
|
16
|
+
$stderr.puts "XSD::XMLParser::OxParser.do_parse" if $DEBUG
|
17
|
+
begin
|
18
|
+
require 'htmlentities' # Used to unescape html-escaped chars, if available
|
19
|
+
@decoder = ::HTMLEntities.new(:expanded)
|
20
|
+
rescue LoadError
|
21
|
+
@decoder = nil
|
22
|
+
end
|
23
|
+
handler = OxDocHandler.new(self, @decoder)
|
24
|
+
|
25
|
+
string = string_or_readable.respond_to?(:read) ? string_or_readable.read : StringIO.new(string_or_readable)
|
26
|
+
if @decoder.nil?
|
27
|
+
# Use the built-in conversion with Ox.
|
28
|
+
::Ox.sax_parse(handler, string, {:symbolize=> false, :convert_special=> true, :skip=> :skip_return} )
|
29
|
+
else
|
30
|
+
# Use HTMLEntities Decoder. Leave the special-character conversion alone and let HTMLEntities decode it for us.
|
31
|
+
::Ox.sax_parse(handler, string, {})
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
public :start_element
|
36
|
+
public :end_element
|
37
|
+
public :characters
|
38
|
+
public :xmldecl_encoding=
|
39
|
+
|
40
|
+
add_factory(self)
|
41
|
+
end
|
42
|
+
|
43
|
+
class OxDocHandler
|
44
|
+
|
45
|
+
def initialize(owner, decoder)
|
46
|
+
@owner = owner
|
47
|
+
@decoder = decoder
|
48
|
+
reset_for_next_element
|
49
|
+
end
|
50
|
+
|
51
|
+
def attr(key, val)
|
52
|
+
@attr_hash[key.to_s]=val
|
53
|
+
end
|
54
|
+
|
55
|
+
def attrs_done
|
56
|
+
unless @element_name.nil?
|
57
|
+
@owner.start_element(@element_name, @attr_hash)
|
58
|
+
reset_for_next_element
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
def start_element(name)
|
63
|
+
@element_name = name.to_s
|
64
|
+
end
|
65
|
+
|
66
|
+
def end_element(name)
|
67
|
+
name = name.to_s
|
68
|
+
@owner.end_element(name) unless @element_name.nil?
|
69
|
+
end
|
70
|
+
|
71
|
+
def text(t)
|
72
|
+
@decoder.nil? ? @owner.characters(t) : @owner.characters(@decoder.decode(t))
|
73
|
+
end
|
74
|
+
|
75
|
+
alias_method :cdata, :text
|
76
|
+
|
77
|
+
|
78
|
+
def instruct(n)
|
79
|
+
# Set @element_name to nil so DocHandler does nothing with attrs or element name. This is the outer "XML" tag.
|
80
|
+
@element_name = nil
|
81
|
+
end
|
82
|
+
|
83
|
+
def end_instruct(n)
|
84
|
+
@owner.xmldecl_encoding= @attr_hash['encoding']
|
85
|
+
reset_for_next_element
|
86
|
+
end
|
87
|
+
|
88
|
+
private
|
89
|
+
|
90
|
+
def reset_for_next_element
|
91
|
+
@attr_hash = {}
|
92
|
+
@element_name = ""
|
93
|
+
end
|
94
|
+
end
|
95
|
+
|
96
|
+
end
|
97
|
+
end
|
@@ -0,0 +1,101 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
# XSD4R - XML Instance parser library.
|
3
|
+
# Copyright (C) 2000-2007 NAKAMURA, Hiroshi <nahi@ruby-lang.org>.
|
4
|
+
|
5
|
+
# This program is copyrighted free software by NAKAMURA, Hiroshi. You can
|
6
|
+
# redistribute it and/or modify it under the same terms of Ruby's license;
|
7
|
+
# either the dual license version in 2003, or any later version.
|
8
|
+
|
9
|
+
|
10
|
+
require 'xsd/qname'
|
11
|
+
require 'xsd/ns'
|
12
|
+
require 'xsd/charset'
|
13
|
+
|
14
|
+
module XSD
|
15
|
+
module XMLParser
|
16
|
+
|
17
|
+
|
18
|
+
class Parser
|
19
|
+
class ParseError < Error; end
|
20
|
+
class FormatDecodeError < ParseError; end
|
21
|
+
class UnknownElementError < FormatDecodeError; end
|
22
|
+
class UnknownAttributeError < FormatDecodeError; end
|
23
|
+
class UnexpectedElementError < FormatDecodeError; end
|
24
|
+
class ElementConstraintError < FormatDecodeError; end
|
25
|
+
class ParserError < ParseError; end
|
26
|
+
|
27
|
+
@@parser_factory = nil
|
28
|
+
|
29
|
+
def self.factory
|
30
|
+
@@parser_factory
|
31
|
+
end
|
32
|
+
|
33
|
+
def self.create_parser(host, opt = {})
|
34
|
+
unless @@parser_factory
|
35
|
+
raise ParserError.new("illegal XML parser configuration")
|
36
|
+
end
|
37
|
+
@@parser_factory.new(host, opt)
|
38
|
+
end
|
39
|
+
|
40
|
+
def self.add_factory(factory)
|
41
|
+
if $DEBUG
|
42
|
+
puts "Set #{ factory } as XML processor."
|
43
|
+
end
|
44
|
+
@@parser_factory = factory
|
45
|
+
end
|
46
|
+
|
47
|
+
public
|
48
|
+
|
49
|
+
attr_accessor :charset
|
50
|
+
|
51
|
+
def initialize(host, opt = {})
|
52
|
+
@host = host
|
53
|
+
@charset = opt[:charset] || nil
|
54
|
+
end
|
55
|
+
|
56
|
+
def parse(string_or_readable)
|
57
|
+
@textbuf = ''
|
58
|
+
prologue
|
59
|
+
do_parse(string_or_readable)
|
60
|
+
epilogue
|
61
|
+
end
|
62
|
+
|
63
|
+
private
|
64
|
+
|
65
|
+
def do_parse(string_or_readable)
|
66
|
+
raise ParserError.new(
|
67
|
+
'Method do_parse must be defined in derived class.')
|
68
|
+
end
|
69
|
+
|
70
|
+
def start_element(name, attrs)
|
71
|
+
@host.start_element(name, attrs)
|
72
|
+
end
|
73
|
+
|
74
|
+
def characters(text)
|
75
|
+
@host.characters(text)
|
76
|
+
end
|
77
|
+
|
78
|
+
def end_element(name)
|
79
|
+
@host.end_element(name)
|
80
|
+
end
|
81
|
+
|
82
|
+
def prologue
|
83
|
+
end
|
84
|
+
|
85
|
+
def epilogue
|
86
|
+
end
|
87
|
+
|
88
|
+
def xmldecl_encoding=(charset)
|
89
|
+
if @charset.nil?
|
90
|
+
@charset = charset
|
91
|
+
p "encoding definition: #{ charset } is configured." if $DEBUG
|
92
|
+
else
|
93
|
+
# Definition in a stream (like HTTP) has a priority.
|
94
|
+
p "encoding definition: #{ charset } is ignored." if $DEBUG
|
95
|
+
end
|
96
|
+
end
|
97
|
+
end
|
98
|
+
|
99
|
+
|
100
|
+
end
|
101
|
+
end
|
@@ -0,0 +1,54 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
# XSD4R - REXMLParser XML parser library.
|
3
|
+
# Copyright (C) 2000-2007 NAKAMURA, Hiroshi <nahi@ruby-lang.org>.
|
4
|
+
|
5
|
+
# This program is copyrighted free software by NAKAMURA, Hiroshi. You can
|
6
|
+
# redistribute it and/or modify it under the same terms of Ruby's license;
|
7
|
+
# either the dual license version in 2003, or any later version.
|
8
|
+
|
9
|
+
|
10
|
+
require 'rexml/streamlistener'
|
11
|
+
require 'rexml/document'
|
12
|
+
|
13
|
+
|
14
|
+
module XSD
|
15
|
+
module XMLParser
|
16
|
+
|
17
|
+
|
18
|
+
class REXMLParser < XSD::XMLParser::Parser
|
19
|
+
include REXML::StreamListener
|
20
|
+
|
21
|
+
def do_parse(string_or_readable)
|
22
|
+
$stderr.puts "XSD::XMLParser::REXMLParser.do_parse" if $DEBUG
|
23
|
+
REXML::Document.parse_stream(string_or_readable, self)
|
24
|
+
end
|
25
|
+
|
26
|
+
def epilogue
|
27
|
+
end
|
28
|
+
|
29
|
+
def tag_start(name, attrs)
|
30
|
+
start_element(name, attrs)
|
31
|
+
end
|
32
|
+
|
33
|
+
def tag_end(name)
|
34
|
+
end_element(name)
|
35
|
+
end
|
36
|
+
|
37
|
+
def text(text)
|
38
|
+
characters(text)
|
39
|
+
end
|
40
|
+
|
41
|
+
def cdata(content)
|
42
|
+
characters(content)
|
43
|
+
end
|
44
|
+
|
45
|
+
def xmldecl(version, encoding, standalone)
|
46
|
+
send :xmldecl_encoding=, encoding
|
47
|
+
end
|
48
|
+
|
49
|
+
add_factory(self)
|
50
|
+
end
|
51
|
+
|
52
|
+
|
53
|
+
end
|
54
|
+
end
|
@@ -0,0 +1,81 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
# XSD4R - XML Instance parser library.
|
3
|
+
# Copyright (C) 2000-2007 NAKAMURA, Hiroshi <nahi@ruby-lang.org>.
|
4
|
+
|
5
|
+
# This program is copyrighted free software by NAKAMURA, Hiroshi. You can
|
6
|
+
# redistribute it and/or modify it under the same terms of Ruby's license;
|
7
|
+
# either the dual license version in 2003, or any later version.
|
8
|
+
|
9
|
+
require 'xsd/xmlparser/parser'
|
10
|
+
|
11
|
+
module XSD
|
12
|
+
module XMLParser
|
13
|
+
|
14
|
+
def create_parser(host, opt)
|
15
|
+
XSD::XMLParser::Parser.create_parser(host, opt)
|
16
|
+
end
|
17
|
+
module_function :create_parser
|
18
|
+
|
19
|
+
# $1 is necessary.
|
20
|
+
NSParseRegexp = Regexp.new('^xmlns:?(.*)$', nil)
|
21
|
+
|
22
|
+
def filter_ns(ns, attrs)
|
23
|
+
ns_updated = false
|
24
|
+
if attrs.nil? or attrs.empty?
|
25
|
+
return [ns, attrs]
|
26
|
+
end
|
27
|
+
newattrs = {}
|
28
|
+
attrs.each do |key, value|
|
29
|
+
if NSParseRegexp =~ key
|
30
|
+
unless ns_updated
|
31
|
+
ns = ns.clone_ns
|
32
|
+
ns_updated = true
|
33
|
+
end
|
34
|
+
# tag == '' means 'default namespace'
|
35
|
+
# value == '' means 'no default namespace'
|
36
|
+
tag = $1 || ''
|
37
|
+
ns.assign(value, tag)
|
38
|
+
else
|
39
|
+
newattrs[key] = value
|
40
|
+
end
|
41
|
+
end
|
42
|
+
return [ns, newattrs]
|
43
|
+
end
|
44
|
+
module_function :filter_ns
|
45
|
+
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
|
50
|
+
# Provide a means to CHOOSE a preferred XML Parser and loading-order, if multiple parser gems are available.
|
51
|
+
if ENV.has_key?('SOAP4R_PARSERS')
|
52
|
+
parser_list = ENV['SOAP4R_PARSERS'].to_s.split(',')
|
53
|
+
else
|
54
|
+
parser_list = [
|
55
|
+
'oxparser', ## Uses its own C-Ruby Extension
|
56
|
+
'nokogiriparser', ## Depends on LibXML2, LibXSLT, and ZLib
|
57
|
+
'libxmlparser', ## Depends on LibXML2 ; Thread-Safe ; Somewhat Broken re: Namespaces
|
58
|
+
# ----- Pure-Ruby Parsers Below ---- #
|
59
|
+
'ogaparser', ## Pure-Ruby
|
60
|
+
'rexmlparser', ## Pure-Ruby, this is the reference implementation.
|
61
|
+
]
|
62
|
+
end
|
63
|
+
|
64
|
+
# Try to load XML processor.
|
65
|
+
loaded = false
|
66
|
+
parser_list.each do |name|
|
67
|
+
begin
|
68
|
+
require "xsd/xmlparser/#{name}"
|
69
|
+
# XXX: for a workaround of rubygems' require inconsistency
|
70
|
+
# XXX: MUST BE REMOVED IN THE FUTURE
|
71
|
+
raise LoadError unless XSD::XMLParser.constants.find { |c|
|
72
|
+
c.to_s.downcase == name
|
73
|
+
}
|
74
|
+
loaded = true
|
75
|
+
break
|
76
|
+
rescue LoadError
|
77
|
+
end
|
78
|
+
end
|
79
|
+
unless loaded
|
80
|
+
raise RuntimeError.new("XML processor module not found.")
|
81
|
+
end
|
metadata
ADDED
@@ -0,0 +1,240 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: soap4r_es
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Laurence A. Lee, Hiroshi NAKAMURA, Fabiano Pavan
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-05-19 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: httpclient
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '2.6'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '2.6'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: logger-application
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 0.0.2
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.0.2
|
41
|
+
description: Soap4R NextGen (as maintained by RubyJedi) for Ruby 1.8 thru 2.1 and
|
42
|
+
beyond
|
43
|
+
email: rubyjedi@gmail.com, nahi@ruby-lang.org
|
44
|
+
executables:
|
45
|
+
- wsdl2ruby_rails.rb
|
46
|
+
- xsd2ruby.rb
|
47
|
+
- wsdl2ruby.rb
|
48
|
+
extensions: []
|
49
|
+
extra_rdoc_files: []
|
50
|
+
files:
|
51
|
+
- bin/wsdl2ruby.rb
|
52
|
+
- bin/wsdl2ruby_rails.rb
|
53
|
+
- bin/xsd2ruby.rb
|
54
|
+
- lib/soap/attachment.rb
|
55
|
+
- lib/soap/attrproxy.rb
|
56
|
+
- lib/soap/baseData.rb
|
57
|
+
- lib/soap/element.rb
|
58
|
+
- lib/soap/encodingstyle/aspDotNetHandler.rb
|
59
|
+
- lib/soap/encodingstyle/handler.rb
|
60
|
+
- lib/soap/encodingstyle/literalHandler.rb
|
61
|
+
- lib/soap/encodingstyle/soapHandler.rb
|
62
|
+
- lib/soap/filter.rb
|
63
|
+
- lib/soap/filter/filterchain.rb
|
64
|
+
- lib/soap/filter/handler.rb
|
65
|
+
- lib/soap/filter/streamhandler.rb
|
66
|
+
- lib/soap/generator.rb
|
67
|
+
- lib/soap/header/handler.rb
|
68
|
+
- lib/soap/header/handlerset.rb
|
69
|
+
- lib/soap/header/mappinghandler.rb
|
70
|
+
- lib/soap/header/simplehandler.rb
|
71
|
+
- lib/soap/httpconfigloader.rb
|
72
|
+
- lib/soap/mapping.rb
|
73
|
+
- lib/soap/mapping/encodedregistry.rb
|
74
|
+
- lib/soap/mapping/factory.rb
|
75
|
+
- lib/soap/mapping/literalregistry.rb
|
76
|
+
- lib/soap/mapping/mapping.rb
|
77
|
+
- lib/soap/mapping/registry.rb
|
78
|
+
- lib/soap/mapping/rubytypeFactory.rb
|
79
|
+
- lib/soap/mapping/schemadefinition.rb
|
80
|
+
- lib/soap/mapping/typeMap.rb
|
81
|
+
- lib/soap/mapping/wsdlencodedregistry.rb
|
82
|
+
- lib/soap/mapping/wsdlliteralregistry.rb
|
83
|
+
- lib/soap/marshal.rb
|
84
|
+
- lib/soap/mimemessage.rb
|
85
|
+
- lib/soap/nestedexception.rb
|
86
|
+
- lib/soap/netHttpClient.rb
|
87
|
+
- lib/soap/ns.rb
|
88
|
+
- lib/soap/parser.rb
|
89
|
+
- lib/soap/processor.rb
|
90
|
+
- lib/soap/property.rb
|
91
|
+
- lib/soap/proxy.rb
|
92
|
+
- lib/soap/rpc/cgistub.rb
|
93
|
+
- lib/soap/rpc/driver.rb
|
94
|
+
- lib/soap/rpc/element.rb
|
95
|
+
- lib/soap/rpc/httpserver.rb
|
96
|
+
- lib/soap/rpc/methodDef.rb
|
97
|
+
- lib/soap/rpc/proxy.rb
|
98
|
+
- lib/soap/rpc/router.rb
|
99
|
+
- lib/soap/rpc/rpc.rb
|
100
|
+
- lib/soap/rpc/soaplet.rb
|
101
|
+
- lib/soap/rpc/standaloneServer.rb
|
102
|
+
- lib/soap/soap.rb
|
103
|
+
- lib/soap/streamHandler.rb
|
104
|
+
- lib/soap/version.rb
|
105
|
+
- lib/soap/wsdlDriver.rb
|
106
|
+
- lib/wsdl/binding.rb
|
107
|
+
- lib/wsdl/data.rb
|
108
|
+
- lib/wsdl/definitions.rb
|
109
|
+
- lib/wsdl/documentation.rb
|
110
|
+
- lib/wsdl/import.rb
|
111
|
+
- lib/wsdl/importer.rb
|
112
|
+
- lib/wsdl/info.rb
|
113
|
+
- lib/wsdl/message.rb
|
114
|
+
- lib/wsdl/operation.rb
|
115
|
+
- lib/wsdl/operationBinding.rb
|
116
|
+
- lib/wsdl/param.rb
|
117
|
+
- lib/wsdl/parser.rb
|
118
|
+
- lib/wsdl/part.rb
|
119
|
+
- lib/wsdl/port.rb
|
120
|
+
- lib/wsdl/portType.rb
|
121
|
+
- lib/wsdl/service.rb
|
122
|
+
- lib/wsdl/soap/address.rb
|
123
|
+
- lib/wsdl/soap/binding.rb
|
124
|
+
- lib/wsdl/soap/body.rb
|
125
|
+
- lib/wsdl/soap/cgiStubCreator.rb
|
126
|
+
- lib/wsdl/soap/classDefCreator.rb
|
127
|
+
- lib/wsdl/soap/classDefCreatorSupport.rb
|
128
|
+
- lib/wsdl/soap/classNameCreator.rb
|
129
|
+
- lib/wsdl/soap/clientSkeltonCreator.rb
|
130
|
+
- lib/wsdl/soap/complexType.rb
|
131
|
+
- lib/wsdl/soap/data.rb
|
132
|
+
- lib/wsdl/soap/definitions.rb
|
133
|
+
- lib/wsdl/soap/driverCreator.rb
|
134
|
+
- lib/wsdl/soap/element.rb
|
135
|
+
- lib/wsdl/soap/encodedMappingRegistryCreator.rb
|
136
|
+
- lib/wsdl/soap/fault.rb
|
137
|
+
- lib/wsdl/soap/header.rb
|
138
|
+
- lib/wsdl/soap/headerfault.rb
|
139
|
+
- lib/wsdl/soap/literalMappingRegistryCreator.rb
|
140
|
+
- lib/wsdl/soap/mappingRegistryCreator.rb
|
141
|
+
- lib/wsdl/soap/mappingRegistryCreatorSupport.rb
|
142
|
+
- lib/wsdl/soap/methodDefCreator.rb
|
143
|
+
- lib/wsdl/soap/operation.rb
|
144
|
+
- lib/wsdl/soap/servantSkeltonCreator.rb
|
145
|
+
- lib/wsdl/soap/servletStubCreator.rb
|
146
|
+
- lib/wsdl/soap/standaloneServerStubCreator.rb
|
147
|
+
- lib/wsdl/soap/wsdl2ruby.rb
|
148
|
+
- lib/wsdl/types.rb
|
149
|
+
- lib/wsdl/wsdl.rb
|
150
|
+
- lib/wsdl/xmlSchema/all.rb
|
151
|
+
- lib/wsdl/xmlSchema/annotation.rb
|
152
|
+
- lib/wsdl/xmlSchema/any.rb
|
153
|
+
- lib/wsdl/xmlSchema/anyAttribute.rb
|
154
|
+
- lib/wsdl/xmlSchema/attribute.rb
|
155
|
+
- lib/wsdl/xmlSchema/attributeGroup.rb
|
156
|
+
- lib/wsdl/xmlSchema/choice.rb
|
157
|
+
- lib/wsdl/xmlSchema/complexContent.rb
|
158
|
+
- lib/wsdl/xmlSchema/complexExtension.rb
|
159
|
+
- lib/wsdl/xmlSchema/complexRestriction.rb
|
160
|
+
- lib/wsdl/xmlSchema/complexType.rb
|
161
|
+
- lib/wsdl/xmlSchema/content.rb
|
162
|
+
- lib/wsdl/xmlSchema/data.rb
|
163
|
+
- lib/wsdl/xmlSchema/element.rb
|
164
|
+
- lib/wsdl/xmlSchema/enumeration.rb
|
165
|
+
- lib/wsdl/xmlSchema/fractiondigits.rb
|
166
|
+
- lib/wsdl/xmlSchema/group.rb
|
167
|
+
- lib/wsdl/xmlSchema/import.rb
|
168
|
+
- lib/wsdl/xmlSchema/importHandler.rb
|
169
|
+
- lib/wsdl/xmlSchema/importer.rb
|
170
|
+
- lib/wsdl/xmlSchema/include.rb
|
171
|
+
- lib/wsdl/xmlSchema/length.rb
|
172
|
+
- lib/wsdl/xmlSchema/list.rb
|
173
|
+
- lib/wsdl/xmlSchema/maxexclusive.rb
|
174
|
+
- lib/wsdl/xmlSchema/maxinclusive.rb
|
175
|
+
- lib/wsdl/xmlSchema/maxlength.rb
|
176
|
+
- lib/wsdl/xmlSchema/minexclusive.rb
|
177
|
+
- lib/wsdl/xmlSchema/mininclusive.rb
|
178
|
+
- lib/wsdl/xmlSchema/minlength.rb
|
179
|
+
- lib/wsdl/xmlSchema/parser.rb
|
180
|
+
- lib/wsdl/xmlSchema/pattern.rb
|
181
|
+
- lib/wsdl/xmlSchema/ref.rb
|
182
|
+
- lib/wsdl/xmlSchema/schema.rb
|
183
|
+
- lib/wsdl/xmlSchema/sequence.rb
|
184
|
+
- lib/wsdl/xmlSchema/simpleContent.rb
|
185
|
+
- lib/wsdl/xmlSchema/simpleExtension.rb
|
186
|
+
- lib/wsdl/xmlSchema/simpleRestriction.rb
|
187
|
+
- lib/wsdl/xmlSchema/simpleType.rb
|
188
|
+
- lib/wsdl/xmlSchema/totaldigits.rb
|
189
|
+
- lib/wsdl/xmlSchema/union.rb
|
190
|
+
- lib/wsdl/xmlSchema/unique.rb
|
191
|
+
- lib/wsdl/xmlSchema/whitespace.rb
|
192
|
+
- lib/wsdl/xmlSchema/xsd2ruby.rb
|
193
|
+
- lib/xsd/charset.rb
|
194
|
+
- lib/xsd/codegen.rb
|
195
|
+
- lib/xsd/codegen/classdef.rb
|
196
|
+
- lib/xsd/codegen/commentdef.rb
|
197
|
+
- lib/xsd/codegen/gensupport.rb
|
198
|
+
- lib/xsd/codegen/methoddef.rb
|
199
|
+
- lib/xsd/codegen/moduledef.rb
|
200
|
+
- lib/xsd/datatypes.rb
|
201
|
+
- lib/xsd/datatypes1999.rb
|
202
|
+
- lib/xsd/iconvcharset.rb
|
203
|
+
- lib/xsd/mapping.rb
|
204
|
+
- lib/xsd/namedelements.rb
|
205
|
+
- lib/xsd/ns.rb
|
206
|
+
- lib/xsd/qname.rb
|
207
|
+
- lib/xsd/xmlparser.rb
|
208
|
+
- lib/xsd/xmlparser/libxmlparser.rb
|
209
|
+
- lib/xsd/xmlparser/nokogiriparser.rb
|
210
|
+
- lib/xsd/xmlparser/ogaparser.rb
|
211
|
+
- lib/xsd/xmlparser/oxparser.rb
|
212
|
+
- lib/xsd/xmlparser/parser.rb
|
213
|
+
- lib/xsd/xmlparser/rexmlparser.rb
|
214
|
+
homepage: http://rubyjedi.github.io/soap4r/
|
215
|
+
licenses:
|
216
|
+
- Ruby
|
217
|
+
metadata: {}
|
218
|
+
post_install_message:
|
219
|
+
rdoc_options: []
|
220
|
+
require_paths:
|
221
|
+
- lib
|
222
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
223
|
+
requirements:
|
224
|
+
- - ">="
|
225
|
+
- !ruby/object:Gem::Version
|
226
|
+
version: '0'
|
227
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
228
|
+
requirements:
|
229
|
+
- - ">="
|
230
|
+
- !ruby/object:Gem::Version
|
231
|
+
version: '0'
|
232
|
+
requirements:
|
233
|
+
- none
|
234
|
+
rubyforge_project:
|
235
|
+
rubygems_version: 2.4.8
|
236
|
+
signing_key:
|
237
|
+
specification_version: 4
|
238
|
+
summary: Soap4R-ng - Soap4R (as maintained by RubyJedi) for Ruby 1.8 thru 2.1 and
|
239
|
+
beyond
|
240
|
+
test_files: []
|