Class: Git::Log::Result
- Inherits:
-
Data
- Object
- Data
- Git::Log::Result
- Includes:
- Enumerable
- Defined in:
- lib/git/log.rb
Overview
An immutable, Enumerable collection of Git::Object::Commit objects.
Returned by Git::Log#execute.
Instance Attribute Summary collapse
-
#commits ⇒ Object
readonly
Returns the value of attribute commits.
Instance Method Summary collapse
Instance Attribute Details
#commits ⇒ Object (readonly)
Returns the value of attribute commits
29 30 31 |
# File 'lib/git/log.rb', line 29 def commits @commits end |
Instance Method Details
#[](index)
34 |
# File 'lib/git/log.rb', line 34 def [](index) = commits[index] |
#each(&block)
32 |
# File 'lib/git/log.rb', line 32 def each(&block) = commits.each(&block) |
#last
33 |
# File 'lib/git/log.rb', line 33 def last = commits.last |
#size
36 |
# File 'lib/git/log.rb', line 36 def size = commits.size |
#to_s
35 |
# File 'lib/git/log.rb', line 35 def to_s = map(&:to_s).join("\n") |