Class: Ifin24::Models::Category
- Defined in:
- lib/ifin24/models/category.rb
Instance Attribute Summary collapse
-
#children ⇒ Object
Returns the value of attribute children.
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ Category
constructor
A new instance of Category.
- #to_s ⇒ Object
Constructor Details
#initialize(attributes = {}) ⇒ Category
Returns a new instance of Category.
6 7 8 9 |
# File 'lib/ifin24/models/category.rb', line 6 def initialize(attributes = {}) super(attributes) @children = [] end |
Instance Attribute Details
#children ⇒ Object
Returns the value of attribute children.
4 5 6 |
# File 'lib/ifin24/models/category.rb', line 4 def children @children end |
#id ⇒ Object
Returns the value of attribute id.
3 4 5 |
# File 'lib/ifin24/models/category.rb', line 3 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
3 4 5 |
# File 'lib/ifin24/models/category.rb', line 3 def name @name end |
Instance Method Details
#to_s ⇒ Object
11 12 13 |
# File 'lib/ifin24/models/category.rb', line 11 def to_s @name end |