Class: Dragnet::Repo
- Inherits:
-
Object
- Object
- Dragnet::Repo
- Defined in:
- lib/dragnet/repo.rb
Overview
Represents a repository, (for MTRs which reference multiple repositories in a multi-repo project, often managed with git-repo)
Instance Attribute Summary collapse
-
#files ⇒ Object
Returns the value of attribute files.
-
#path ⇒ Object
Returns the value of attribute path.
-
#sha1 ⇒ Object
Returns the value of attribute sha1.
Instance Method Summary collapse
-
#initialize(args) ⇒ Repo
constructor
A new instance of Repo.
-
#validate ⇒ Object
Validates the
Repo
instance (by checking each of its attributes).
Constructor Details
#initialize(args) ⇒ Repo
Returns a new instance of Repo.
17 18 19 20 21 |
# File 'lib/dragnet/repo.rb', line 17 def initialize(args) @path = args[:path] @sha1 = args[:sha1] @files = args[:files] end |
Instance Attribute Details
#files ⇒ Object
Returns the value of attribute files.
9 10 11 |
# File 'lib/dragnet/repo.rb', line 9 def files @files end |
#path ⇒ Object
Returns the value of attribute path.
9 10 11 |
# File 'lib/dragnet/repo.rb', line 9 def path @path end |
#sha1 ⇒ Object
Returns the value of attribute sha1.
9 10 11 |
# File 'lib/dragnet/repo.rb', line 9 def sha1 @sha1 end |
Instance Method Details
#validate ⇒ Object
Validates the Repo
instance (by checking each of its attributes).
27 28 29 |
# File 'lib/dragnet/repo.rb', line 27 def validate Dragnet::Validators::Entities::RepoValidator.new(self).validate end |