Class: WSDL::SOAP::DriverCreator
- Includes:
- ClassDefCreatorSupport
- Defined in:
- lib/wsdl/soap/driverCreator.rb
Instance Attribute Summary collapse
-
#definitions ⇒ Object
readonly
Returns the value of attribute definitions.
-
#drivername_postfix ⇒ Object
Returns the value of attribute drivername_postfix.
Instance Method Summary collapse
- #dump(porttype = nil) ⇒ Object
-
#initialize(definitions, name_creator, modulepath = nil) ⇒ DriverCreator
constructor
A new instance of DriverCreator.
Methods included from ClassDefCreatorSupport
#assign_const, #basetype_mapped_class, #create_type_name, #dq, #dqname, #dump_method_signature, #mapped_class_basename, #mapped_class_name, #ndq, #nsym, #sym
Methods included from XSD::CodeGen::GenSupport
capitalize, constant?, #format, keyword?, safeconstname, safeconstname?, safemethodname, safemethodname?, safevarname, safevarname?, uncapitalize
Constructor Details
#initialize(definitions, name_creator, modulepath = nil) ⇒ DriverCreator
Returns a new instance of DriverCreator.
26 27 28 29 30 31 |
# File 'lib/wsdl/soap/driverCreator.rb', line 26 def initialize(definitions, name_creator, modulepath = nil) @definitions = definitions @name_creator = name_creator @modulepath = modulepath @drivername_postfix = '' end |
Instance Attribute Details
#definitions ⇒ Object (readonly)
Returns the value of attribute definitions.
23 24 25 |
# File 'lib/wsdl/soap/driverCreator.rb', line 23 def definitions @definitions end |
#drivername_postfix ⇒ Object
Returns the value of attribute drivername_postfix.
24 25 26 |
# File 'lib/wsdl/soap/driverCreator.rb', line 24 def drivername_postfix @drivername_postfix end |
Instance Method Details
#dump(porttype = nil) ⇒ Object
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
# File 'lib/wsdl/soap/driverCreator.rb', line 33 def dump(porttype = nil) result = "require 'soap/rpc/driver'\n\n" if @modulepath @modulepath.each_line do |name| result << "module #{name}\n" end result << "\n" end if porttype.nil? @definitions.porttypes.each do |type| result << dump_porttype(type.name) result << "\n" end else result << dump_porttype(porttype) end if @modulepath result << "\n" @modulepath.each_line do |name| result << "end\n" end end result end |