Class: ReleaseHx::RHYML::History
- Inherits:
-
Object
- Object
- ReleaseHx::RHYML::History
- Defined in:
- lib/releasehx/rhyml/release.rb
Overview
Note:
Manages a collection of Release objects for historical tracking.
This class is currently unused but maintained as part of the core
RHYML data model for future functionality like cross-release analytics.
Instance Attribute Summary collapse
-
#releases ⇒ Object
readonly
Returns the value of attribute releases.
Instance Method Summary collapse
-
#add_release(release) ⇒ Release
Adds a Release to the history.
-
#initialize ⇒ History
constructor
Initializes a new, empty History object.
Constructor Details
#initialize ⇒ History
Initializes a new, empty History object.
127 128 129 |
# File 'lib/releasehx/rhyml/release.rb', line 127 def initialize @releases = [] end |
Instance Attribute Details
#releases ⇒ Object (readonly)
Returns the value of attribute releases.
124 125 126 |
# File 'lib/releasehx/rhyml/release.rb', line 124 def releases @releases end |
Instance Method Details
#add_release(release) ⇒ Release
Adds a Release to the history.
135 136 137 138 139 140 141 |
# File 'lib/releasehx/rhyml/release.rb', line 135 def add_release release raise ArgumentError, 'Release must be a Release object' unless release.is_a? Release @releases << release ReleaseHx.logger.debug "Added Release: #{release.code} (#{release.date})" release end |