Class: WSDL::XMLSchema::Attribute
- Includes:
- Ref
- Defined in:
- lib/wsdl/xmlSchema/attribute.rb
Instance Attribute Summary collapse
-
#arytype ⇒ Object
Returns the value of attribute arytype.
-
#default ⇒ Object
writeonly
Sets the attribute default.
-
#fixed ⇒ Object
writeonly
Sets the attribute fixed.
-
#form ⇒ Object
writeonly
Sets the attribute form.
-
#local_simpletype ⇒ Object
writeonly
Sets the attribute local_simpletype.
-
#name ⇒ Object
writeonly
Sets the attribute name.
-
#type ⇒ Object
writeonly
Sets the attribute type.
-
#use ⇒ Object
writeonly
Sets the attribute use.
Attributes included from Ref
Attributes inherited from Info
Instance Method Summary collapse
-
#initialize ⇒ Attribute
constructor
A new instance of Attribute.
- #parse_attr(attr, value) ⇒ Object
- #parse_element(element) ⇒ Object
- #targetnamespace ⇒ Object
Methods included from Ref
Methods inherited from Info
Constructor Details
#initialize ⇒ Attribute
Returns a new instance of Attribute.
39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 39 def initialize super @use = nil @form = nil @name = nil @type = nil @local_simpletype = nil @default = nil @fixed = nil @ref = nil @refelement = nil @arytype = nil end |
Instance Attribute Details
#arytype ⇒ Object
Returns the value of attribute arytype.
37 38 39 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 37 def arytype @arytype end |
#default=(value) ⇒ Object (writeonly)
Sets the attribute default
26 27 28 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 26 def default=(value) @default = value end |
#fixed=(value) ⇒ Object (writeonly)
Sets the attribute fixed
27 28 29 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 27 def fixed=(value) @fixed = value end |
#form=(value) ⇒ Object (writeonly)
Sets the attribute form
22 23 24 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 22 def form=(value) @form = value end |
#local_simpletype=(value) ⇒ Object (writeonly)
Sets the attribute local_simpletype
25 26 27 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 25 def local_simpletype=(value) @local_simpletype = value end |
#name=(value) ⇒ Object (writeonly)
Sets the attribute name
23 24 25 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 23 def name=(value) @name = value end |
#type=(value) ⇒ Object (writeonly)
Sets the attribute type
24 25 26 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 24 def type=(value) @type = value end |
#use=(value) ⇒ Object (writeonly)
Sets the attribute use
21 22 23 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 21 def use=(value) @use = value end |
Instance Method Details
#parse_attr(attr, value) ⇒ Object
65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 65 def parse_attr(attr, value) case attr when RefAttrName @ref = value when UseAttrName @use = value.source when FormAttrName @form = value.source when NameAttrName if directelement? @name = XSD::QName.new(targetnamespace, value.source) else @name = XSD::QName.new(nil, value.source) end when TypeAttrName @type = value when DefaultAttrName @default = value.source when FixedAttrName @fixed = value.source when ArrayTypeAttrName @arytype = value else nil end end |
#parse_element(element) ⇒ Object
57 58 59 60 61 62 63 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 57 def parse_element(element) case element when SimpleTypeName @local_simpletype = SimpleType.new @local_simpletype end end |
#targetnamespace ⇒ Object
53 54 55 |
# File 'lib/wsdl/xmlSchema/attribute.rb', line 53 def targetnamespace parent.targetnamespace end |