Class: WSDL::XMLSchema::SimpleExtension

Inherits:
Info show all
Defined in:
lib/wsdl/xmlSchema/simpleExtension.rb

Instance Attribute Summary (collapse)

Attributes inherited from Info

#id, #parent, #root

Instance Method Summary (collapse)

Methods inherited from Info

#inspect, #parse_epilogue

Constructor Details

- (SimpleExtension) initialize



21
22
23
24
25
# File 'lib/wsdl/xmlSchema/simpleExtension.rb', line 21

def initialize
  super
  @base = nil
  @attributes = XSD::NamedElements.new
end

Instance Attribute Details

- (Object) attributes (readonly)

Returns the value of attribute attributes



19
20
21
# File 'lib/wsdl/xmlSchema/simpleExtension.rb', line 19

def attributes
  @attributes
end

- (Object) base (readonly)

Returns the value of attribute base



18
19
20
# File 'lib/wsdl/xmlSchema/simpleExtension.rb', line 18

def base
  @base
end

Instance Method Details

- (Object) parse_attr(attr, value)



52
53
54
55
56
57
# File 'lib/wsdl/xmlSchema/simpleExtension.rb', line 52

def parse_attr(attr, value)
  case attr
  when BaseAttrName
    @base = value
  end
end

- (Object) parse_element(element)



35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# File 'lib/wsdl/xmlSchema/simpleExtension.rb', line 35

def parse_element(element)
  case element
  when AttributeName
    o = Attribute.new
    @attributes << o
    o
  when AttributeGroupName
    o = AttributeGroup.new
    @attributes << o
    o
  when AnyAttributeName
    o = AnyAttribute.new
    @attributes << o
    o
  end
end

- (Object) targetnamespace



27
28
29
# File 'lib/wsdl/xmlSchema/simpleExtension.rb', line 27

def targetnamespace
  parent.targetnamespace
end

- (Boolean) valid?(value)



31
32
33
# File 'lib/wsdl/xmlSchema/simpleExtension.rb', line 31

def valid?(value)
  true
end