Class: JAXB2Ruby::Element
Instance Attribute Summary collapse
-
#attributes ⇒ Object
readonly
Returns the value of attribute attributes.
-
#children ⇒ Object
readonly
Returns the value of attribute children.
Attributes inherited from Node
#accessor, #default, #local_name, #name, #namespace, #type
Instance Method Summary collapse
-
#initialize(name, options = {}) ⇒ Element
constructor
A new instance of Element.
- #nillable? ⇒ Boolean
- #root? ⇒ Boolean
- #text? ⇒ Boolean
Methods inherited from Node
Constructor Details
#initialize(name, options = {}) ⇒ Element
Returns a new instance of Element.
102 103 104 105 106 107 108 109 |
# File 'lib/jaxb2ruby/classes.rb', line 102 def initialize(name, = {}) super @text = !![:text] @root = !![:root] @nillable = !![:nillable] @children = [:children] || [] @attributes = [:attributes] || [] end |
Instance Attribute Details
#attributes ⇒ Object (readonly)
Returns the value of attribute attributes.
100 101 102 |
# File 'lib/jaxb2ruby/classes.rb', line 100 def attributes @attributes end |
#children ⇒ Object (readonly)
Returns the value of attribute children.
99 100 101 |
# File 'lib/jaxb2ruby/classes.rb', line 99 def children @children end |
Instance Method Details
#nillable? ⇒ Boolean
111 112 113 |
# File 'lib/jaxb2ruby/classes.rb', line 111 def nillable? @nillable end |
#root? ⇒ Boolean
115 116 117 |
# File 'lib/jaxb2ruby/classes.rb', line 115 def root? @root end |
#text? ⇒ Boolean
119 120 121 |
# File 'lib/jaxb2ruby/classes.rb', line 119 def text? @text end |