Class: Justicecz::Entities::List
- Inherits:
-
Object
- Object
- Justicecz::Entities::List
- Defined in:
- lib/justicecz/entities/list.rb
Instance Attribute Summary collapse
-
#items ⇒ Object
Returns the value of attribute items.
Instance Method Summary collapse
- #<<(company) ⇒ Object
-
#initialize(items = nil) ⇒ List
constructor
A new instance of List.
Constructor Details
#initialize(items = nil) ⇒ List
Returns a new instance of List.
6 7 8 |
# File 'lib/justicecz/entities/list.rb', line 6 def initialize(items = nil) @items = items || [] end |
Instance Attribute Details
#items ⇒ Object
Returns the value of attribute items.
4 5 6 |
# File 'lib/justicecz/entities/list.rb', line 4 def items @items end |
Instance Method Details
#<<(company) ⇒ Object
10 11 12 |
# File 'lib/justicecz/entities/list.rb', line 10 def <<(company) items << company end |