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
137 138 139 |
# File 'core-docs/toys/utils/git_cache.rb', line 137 def last_accessed @last_accessed end |
#last_updated ⇒ Time (readonly)
The timestamp when this ref was last updated
144 145 146 |
# File 'core-docs/toys/utils/git_cache.rb', line 144 def last_updated @last_updated end |
#ref ⇒ String (readonly)
The git ref
123 124 125 |
# File 'core-docs/toys/utils/git_cache.rb', line 123 def ref @ref end |
#sha ⇒ String (readonly)
The git sha last associated with the ref
130 131 132 |
# File 'core-docs/toys/utils/git_cache.rb', line 130 def sha @sha end |
Instance Method Details
#<=>(other) ⇒ Integer
Comparison function
161 162 163 |
# File 'core-docs/toys/utils/git_cache.rb', line 161 def <=>(other) # Source available in the toys-core gem end |
#to_h ⇒ Hash
Convert this RefInfo to a hash suitable for JSON output
151 152 153 |
# File 'core-docs/toys/utils/git_cache.rb', line 151 def to_h # Source available in the toys-core gem end |