Class: SVNx::CatCommandArgs
- Inherits:
-
CommandArgs
- Object
- CommandArgs
- SVNx::CatCommandArgs
- Defined in:
- lib/svnx/cat/command.rb
Instance Attribute Summary collapse
-
#revision ⇒ Object
readonly
Returns the value of attribute revision.
-
#use_cache ⇒ Object
readonly
Returns the value of attribute use_cache.
Attributes inherited from CommandArgs
Instance Method Summary collapse
-
#initialize(args = Hash.new) ⇒ CatCommandArgs
constructor
A new instance of CatCommandArgs.
- #to_a ⇒ Object
Constructor Details
#initialize(args = Hash.new) ⇒ CatCommandArgs
Returns a new instance of CatCommandArgs.
23 24 25 26 27 |
# File 'lib/svnx/cat/command.rb', line 23 def initialize args = Hash.new @use_cache = args[:use_cache].nil? || args[:use_cache] @revision = args[:revision] super end |
Instance Attribute Details
#revision ⇒ Object (readonly)
Returns the value of attribute revision.
20 21 22 |
# File 'lib/svnx/cat/command.rb', line 20 def revision @revision end |
#use_cache ⇒ Object (readonly)
Returns the value of attribute use_cache.
21 22 23 |
# File 'lib/svnx/cat/command.rb', line 21 def use_cache @use_cache end |
Instance Method Details
#to_a ⇒ Object
29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/svnx/cat/command.rb', line 29 def to_a ary = Array.new if @revision @revision.each do |rev| ary << "-r#{rev}" end end if @path ary << @path end end |