Class: Disloku::FileChange
- Inherits:
-
Object
- Object
- Disloku::FileChange
- Defined in:
- lib/disloku/FileChange.rb
Instance Attribute Summary collapse
-
#changeType ⇒ Object
Returns the value of attribute changeType.
-
#dirty ⇒ Object
Returns the value of attribute dirty.
-
#repository ⇒ Object
Returns the value of attribute repository.
Instance Method Summary collapse
- #getFile(target) ⇒ Object
-
#initialize(repository, fullPath, changeType, dirty) ⇒ FileChange
constructor
A new instance of FileChange.
- #to_s ⇒ Object
Constructor Details
#initialize(repository, fullPath, changeType, dirty) ⇒ FileChange
Returns a new instance of FileChange.
7 8 9 10 11 12 |
# File 'lib/disloku/FileChange.rb', line 7 def initialize(repository, fullPath, changeType, dirty) @repository = repository @fullPath = fullPath @changeType = changeType @dirty = dirty end |
Instance Attribute Details
#changeType ⇒ Object
Returns the value of attribute changeType.
5 6 7 |
# File 'lib/disloku/FileChange.rb', line 5 def changeType @changeType end |
#dirty ⇒ Object
Returns the value of attribute dirty.
5 6 7 |
# File 'lib/disloku/FileChange.rb', line 5 def dirty @dirty end |
#repository ⇒ Object
Returns the value of attribute repository.
5 6 7 |
# File 'lib/disloku/FileChange.rb', line 5 def repository @repository end |
Instance Method Details
#getFile(target) ⇒ Object
14 15 16 |
# File 'lib/disloku/FileChange.rb', line 14 def getFile(target) return Util::File.new(@fullPath, @repository.root, target, self) end |
#to_s ⇒ Object
18 19 20 |
# File 'lib/disloku/FileChange.rb', line 18 def to_s() return "<#{@changeType}> #{@fullPath}" + (@dirty ? " (dirty)" : "") end |