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.



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

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.



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

def attributes=(value)
  @attributes = value
end

#name=(value) ⇒ Object (writeonly)

required



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

def name=(value)
  @name = value
end

Instance Method Details

#parse_attr(attr, value) ⇒ Object



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

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



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

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

#targetnamespaceObject



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

def targetnamespace
  parent.targetnamespace
end