Class: DataType

Inherits:
Tag
  • Object
show all
Defined in:
lib/xmimodel/data_type.rb

Instance Attribute Summary collapse

Attributes inherited from Tag

#id, #parent_tag, #xml

Instance Method Summary collapse

Methods inherited from Tag

#xml_root

Constructor Details

#initialize(xml, parent_tag) ⇒ DataType

Returns a new instance of DataType.


9
10
11
12
13
# File 'lib/xmimodel/data_type.rb', line 9

def initialize(xml, parent_tag)
	super(xml, parent_tag)

	@name = xml.attribute("name").to_s.strip		
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name


7
8
9
# File 'lib/xmimodel/data_type.rb', line 7

def name
  @name
end

Instance Method Details

#to_sObject


15
16
17
# File 'lib/xmimodel/data_type.rb', line 15

def to_s
	"DataType[#{@name}]"
end