Class: LolSoap::WSDL::Element

Inherits:
Object
  • Object
show all
Defined in:
lib/lolsoap/wsdl/element.rb

Direct Known Subclasses

OperationIOPart

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(wsdl, name, prefix, type_reference, singular = true) ⇒ Element

Returns a new instance of Element.



5
6
7
8
9
10
11
# File 'lib/lolsoap/wsdl/element.rb', line 5

def initialize(wsdl, name, prefix, type_reference, singular = true)
  @wsdl           = wsdl
  @name           = name
  @prefix         = prefix
  @type_reference = type_reference
  @singular       = singular
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



3
4
5
# File 'lib/lolsoap/wsdl/element.rb', line 3

def name
  @name
end

#prefixObject (readonly)

Returns the value of attribute prefix.



3
4
5
# File 'lib/lolsoap/wsdl/element.rb', line 3

def prefix
  @prefix
end

#type_referenceObject (readonly)

Returns the value of attribute type_reference.



3
4
5
# File 'lib/lolsoap/wsdl/element.rb', line 3

def type_reference
  @type_reference
end

Instance Method Details

#inspectObject



21
22
23
# File 'lib/lolsoap/wsdl/element.rb', line 21

def inspect
  "<#{self.class} name=#{prefix_and_name.inspect} type=#{type.to_s.inspect}>"
end

#prefix_and_nameObject



25
26
27
# File 'lib/lolsoap/wsdl/element.rb', line 25

def prefix_and_name
  "#{prefix}:#{name}"
end

#singular?Boolean

Returns:

  • (Boolean)


17
18
19
# File 'lib/lolsoap/wsdl/element.rb', line 17

def singular?
  @singular == true
end

#typeObject



13
14
15
# File 'lib/lolsoap/wsdl/element.rb', line 13

def type
  type_reference.type
end