Module: WsdlMapper::Dom::ShallowSchema

Includes:
Enumerable
Included in:
BuiltinType, SoapEncodingType
Defined in:
lib/wsdl_mapper/dom/shallow_schema.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Instance Attribute Details

- (Object) namespace

Returns the value of attribute namespace



6
7
8
# File 'lib/wsdl_mapper/dom/shallow_schema.rb', line 6

def namespace
  @namespace
end

Instance Method Details

- (Object) [](name)



14
15
16
17
# File 'lib/wsdl_mapper/dom/shallow_schema.rb', line 14

def [](name)
  n = name.is_a?(WsdlMapper::Dom::Name) ? name.name : name
  types[name]
end

- (Object) build(name)



19
20
21
22
# File 'lib/wsdl_mapper/dom/shallow_schema.rb', line 19

def build(name)
  n = name.is_a?(WsdlMapper::Dom::Name) ? name : Name.get(namespace, name)
  new n
end

- (Boolean) builtin?(name)

Returns:

  • (Boolean)


30
31
32
# File 'lib/wsdl_mapper/dom/shallow_schema.rb', line 30

def builtin?(name)
  return name.ns == namespace
end

- (Object) each(&block)



26
27
28
# File 'lib/wsdl_mapper/dom/shallow_schema.rb', line 26

def each(&block)
  types.values.each &block
end

- (Object) types



8
9
10
11
12
# File 'lib/wsdl_mapper/dom/shallow_schema.rb', line 8

def types
  @types ||= Hash.new do |h, k|
    h[k] = build k
  end
end