Class: Basketcase::ElementStatus
- Inherits:
-
Object
- Object
- Basketcase::ElementStatus
- Defined in:
- lib/basketcase.rb
Overview
Represents the status of an element
Instance Attribute Summary collapse
-
#base_version ⇒ Object
readonly
Returns the value of attribute base_version.
-
#path ⇒ Object
readonly
Returns the value of attribute path.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(path, status, base_version = nil) ⇒ ElementStatus
constructor
A new instance of ElementStatus.
- #to_s ⇒ Object
Constructor Details
#initialize(path, status, base_version = nil) ⇒ ElementStatus
Returns a new instance of ElementStatus.
103 104 105 106 107 |
# File 'lib/basketcase.rb', line 103 def initialize(path, status, base_version = nil) @path = path @status = status @base_version = base_version end |
Instance Attribute Details
#base_version ⇒ Object (readonly)
Returns the value of attribute base_version.
109 110 111 |
# File 'lib/basketcase.rb', line 109 def base_version @base_version end |
#path ⇒ Object (readonly)
Returns the value of attribute path.
109 110 111 |
# File 'lib/basketcase.rb', line 109 def path @path end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
109 110 111 |
# File 'lib/basketcase.rb', line 109 def status @status end |
Instance Method Details
#to_s ⇒ Object
111 112 113 114 115 |
# File 'lib/basketcase.rb', line 111 def to_s s = "#{path} (#{status})" s += " [#{base_version}]" if base_version return s end |