Class WSDL::XMLSchema::ComplexContent
In: wsdl/xmlSchema/complexContent.rb
Parent: Info

Methods

Attributes

attributes  [R] 
base  [RW] 
content  [R] 
derivetype  [R] 

Public Class methods

[Source]

# File wsdl/xmlSchema/complexContent.rb, line 23
  def initialize
    super
    @base = nil
    @derivetype = nil
    @content = nil
    @attributes = XSD::NamedElements.new
    @basetype = nil
  end

Public Instance methods

[Source]

# File wsdl/xmlSchema/complexContent.rb, line 40
  def basetype
    @basetype ||= root.collect_complextypes[@base]
  end

[Source]

# File wsdl/xmlSchema/complexContent.rb, line 36
  def elementformdefault
    parent.elementformdefault
  end

[Source]

# File wsdl/xmlSchema/complexContent.rb, line 77
  def parse_attr(attr, value)
    if @derivetype.nil?
      return nil
    end
    case attr
    when BaseAttrName
      @base = value
    else
      nil
    end
  end

[Source]

# File wsdl/xmlSchema/complexContent.rb, line 44
  def parse_element(element)
    case element
    when RestrictionName, ExtensionName
      @derivetype = element.name
      self
    when AllName
      if @derivetype.nil?
        raise Parser::ElementConstraintError.new("base attr not found.")
      end
      @content = All.new
      @content
    when SequenceName
      if @derivetype.nil?
        raise Parser::ElementConstraintError.new("base attr not found.")
      end
      @content = Sequence.new
      @content
    when ChoiceName
      if @derivetype.nil?
        raise Parser::ElementConstraintError.new("base attr not found.")
      end
      @content = Choice.new
      @content
    when AttributeName
      if @derivetype.nil?
        raise Parser::ElementConstraintError.new("base attr not found.")
      end
      o = Attribute.new
      @attributes << o
      o
    end
  end

[Source]

# File wsdl/xmlSchema/complexContent.rb, line 32
  def targetnamespace
    parent.targetnamespace
  end

[Validate]

ruby-doc.org is a service of James Britt and Happy Camper Studios, a Ruby application development company in Phoenix, AZ.

Documentation content on ruby-doc.org is provided by remarkable members of the Ruby community.

For more information on the Ruby programming language, visit ruby-lang.org.

Want to help improve Ruby's API docs? See Ruby Documentation Guidelines.