Class: WSDL::SOAP::ClassDefCreator
- Inherits:
-
Object
- Object
- WSDL::SOAP::ClassDefCreator
- Includes:
- ClassDefCreatorSupport
- Defined in:
- lib/wsdl/soap/classDefCreator.rb
Constant Summary collapse
- DEFAULT_ITEM_NAME =
XSD::QName.new(nil, 'item')
Instance Method Summary collapse
- #dump(type = nil) ⇒ Object
-
#initialize(definitions) ⇒ ClassDefCreator
constructor
A new instance of ClassDefCreator.
Methods included from ClassDefCreatorSupport
#basetype_mapped_class, #create_class_name, #dq, #dqname, #dump_method_signature, #ndq, #sym
Constructor Details
#initialize(definitions) ⇒ ClassDefCreator
Returns a new instance of ClassDefCreator.
21 22 23 24 25 26 27 28 29 |
# File 'lib/wsdl/soap/classDefCreator.rb', line 21 def initialize(definitions) @elements = definitions.collect_elements @simpletypes = definitions.collect_simpletypes @complextypes = definitions.collect_complextypes @faulttypes = nil if definitions.respond_to?(:collect_faulttypes) @faulttypes = definitions.collect_faulttypes end end |
Instance Method Details
#dump(type = nil) ⇒ Object
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/wsdl/soap/classDefCreator.rb', line 31 def dump(type = nil) result = "require 'xsd/qname'\n" if type result = dump_classdef(type.name, type) else str = dump_element unless str.empty? result << "\n" unless result.empty? result << str end str = dump_complextype unless str.empty? result << "\n" unless result.empty? result << str end str = dump_simpletype unless str.empty? result << "\n" unless result.empty? result << str end end result end |