Class: Ablab::Group
- Inherits:
-
Object
- Object
- Ablab::Group
- Defined in:
- lib/ablab.rb
Instance Attribute Summary collapse
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#weight ⇒ Object
readonly
Returns the value of attribute weight.
Instance Method Summary collapse
-
#initialize(name, description = nil, weight = nil) ⇒ Group
constructor
A new instance of Group.
Constructor Details
#initialize(name, description = nil, weight = nil) ⇒ Group
Returns a new instance of Group.
206 207 208 209 |
# File 'lib/ablab.rb', line 206 def initialize(name, description = nil, weight = nil) @name, @description = name.to_sym, description @weight = weight || 1 end |
Instance Attribute Details
#description ⇒ Object (readonly)
Returns the value of attribute description.
204 205 206 |
# File 'lib/ablab.rb', line 204 def description @description end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
204 205 206 |
# File 'lib/ablab.rb', line 204 def name @name end |
#weight ⇒ Object (readonly)
Returns the value of attribute weight.
204 205 206 |
# File 'lib/ablab.rb', line 204 def weight @weight end |