Class: Toys::Utils::GitCache::RefInfo
- Inherits:
-
Object
- Object
- Toys::Utils::GitCache::RefInfo
- Includes:
- Comparable
- Defined in:
- core-docs/toys/utils/git_cache.rb
Overview
Defined in the toys-core gem
Information about a git ref used in a cache.
Instance Attribute Summary collapse
-
#last_accessed ⇒ Time?
readonly
The timestamp when this ref was last accessed.
-
#last_updated ⇒ Time?
readonly
The timestamp when this ref was last updated.
-
#ref ⇒ String
readonly
The git ref.
-
#sha ⇒ String
readonly
The git sha last associated with the ref.
Instance Method Summary collapse
-
#<=>(other) ⇒ Integer
Comparison function.
-
#to_h ⇒ Hash
Convert this RefInfo to a hash suitable for JSON output.
Instance Attribute Details
#last_accessed ⇒ Time? (readonly)
The timestamp when this ref was last accessed
286 287 288 |
# File 'core-docs/toys/utils/git_cache.rb', line 286 def last_accessed @last_accessed end |
#last_updated ⇒ Time? (readonly)
The timestamp when this ref was last updated
293 294 295 |
# File 'core-docs/toys/utils/git_cache.rb', line 293 def last_updated @last_updated end |
#ref ⇒ String (readonly)
The git ref
272 273 274 |
# File 'core-docs/toys/utils/git_cache.rb', line 272 def ref @ref end |
#sha ⇒ String (readonly)
The git sha last associated with the ref
279 280 281 |
# File 'core-docs/toys/utils/git_cache.rb', line 279 def sha @sha end |
Instance Method Details
#<=>(other) ⇒ Integer
Comparison function
310 311 312 |
# File 'core-docs/toys/utils/git_cache.rb', line 310 def <=>(other) # Source available in the toys-core gem end |
#to_h ⇒ Hash
Convert this RefInfo to a hash suitable for JSON output
300 301 302 |
# File 'core-docs/toys/utils/git_cache.rb', line 300 def to_h # Source available in the toys-core gem end |