Class: Dependabot::GitTagWithDetail
- Inherits:
-
Object
- Object
- Dependabot::GitTagWithDetail
- Extended by:
- T::Sig
- Defined in:
- lib/dependabot/git_tag_with_detail.rb
Instance Attribute Summary collapse
-
#release_date ⇒ Object
Returns the value of attribute release_date.
-
#tag ⇒ Object
Returns the value of attribute tag.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(tag:, release_date: nil) ⇒ GitTagWithDetail
constructor
A new instance of GitTagWithDetail.
- #to_h ⇒ Object
Constructor Details
#initialize(tag:, release_date: nil) ⇒ GitTagWithDetail
Returns a new instance of GitTagWithDetail.
22 23 24 25 |
# File 'lib/dependabot/git_tag_with_detail.rb', line 22 def initialize(tag:, release_date: nil) @tag = tag @release_date = release_date end |
Instance Attribute Details
#release_date ⇒ Object
Returns the value of attribute release_date.
14 15 16 |
# File 'lib/dependabot/git_tag_with_detail.rb', line 14 def release_date @release_date end |
#tag ⇒ Object
Returns the value of attribute tag.
11 12 13 |
# File 'lib/dependabot/git_tag_with_detail.rb', line 11 def tag @tag end |
Instance Method Details
#==(other) ⇒ Object
28 29 30 31 32 33 34 35 |
# File 'lib/dependabot/git_tag_with_detail.rb', line 28 def ==(other) case other when GitTagWithDetail to_h == other.to_h else false end end |
#to_h ⇒ Object
38 39 40 41 42 43 |
# File 'lib/dependabot/git_tag_with_detail.rb', line 38 def to_h { tag: tag, release_date: release_date }.compact end |