Class: WSDL::XMLSchema::AttributeGroup

Inherits:
Info show all
Includes:
Ref
Defined in:
lib/wsdl/xmlSchema/attributeGroup.rb

Instance Attribute Summary collapse

Attributes included from Ref

#ref

Attributes inherited from Info

#id, #parent, #root

Instance Method Summary collapse

Methods included from Ref

included

Methods inherited from Info

#inspect, #parse_epilogue

Constructor Details

#initializeAttributeGroup

Returns a new instance of AttributeGroup.



26
27
28
29
30
31
32
# File 'lib/wsdl/xmlSchema/attributeGroup.rb', line 26

def initialize
  super
  @name = nil
  @attributes = nil
  @ref = nil
  @refelement = nil
end

Instance Attribute Details

#attributes=(value) ⇒ Object (writeonly)

Sets the attribute attributes

Parameters:

  • value

    the value to set the attribute attributes to.



21
22
23
# File 'lib/wsdl/xmlSchema/attributeGroup.rb', line 21

def attributes=(value)
  @attributes = value
end

#name=(value) ⇒ Object (writeonly)

required



20
21
22
# File 'lib/wsdl/xmlSchema/attributeGroup.rb', line 20

def name=(value)
  @name = value
end

Instance Method Details

#parse_attr(attr, value) ⇒ Object



48
49
50
51
52
53
54
55
56
57
# File 'lib/wsdl/xmlSchema/attributeGroup.rb', line 48

def parse_attr(attr, value)
  case attr
  when NameAttrName
    @name = XSD::QName.new(targetnamespace, value.source)
  when RefAttrName
    @ref = value
  else
    nil
  end
end

#parse_element(element) ⇒ Object



38
39
40
41
42
43
44
45
46
# File 'lib/wsdl/xmlSchema/attributeGroup.rb', line 38

def parse_element(element)
  case element
  when AttributeName
    @attributes ||= XSD::NamedElements.new
    o = Attribute.new
    @attributes << o
    o
  end
end

#targetnamespaceObject



34
35
36
# File 'lib/wsdl/xmlSchema/attributeGroup.rb', line 34

def targetnamespace
  parent.targetnamespace
end