Class: Rosette::Client::Commands::Command
- Inherits:
-
Object
- Object
- Rosette::Client::Commands::Command
- Defined in:
- lib/rosette/client/commands.rb
Direct Known Subclasses
CommitCommand, DiffCommand, PullCommand, RepoSnapshotCommand, SnapshotCommand, StatusCommand
Instance Attribute Summary collapse
-
#api ⇒ Object
readonly
Returns the value of attribute api.
-
#args ⇒ Object
readonly
Returns the value of attribute args.
-
#repo ⇒ Object
readonly
Returns the value of attribute repo.
-
#terminal ⇒ Object
readonly
Returns the value of attribute terminal.
-
#writer ⇒ Object
readonly
Returns the value of attribute writer.
Instance Method Summary collapse
-
#initialize(api, terminal, writer, repo, argv) ⇒ Command
constructor
A new instance of Command.
Constructor Details
#initialize(api, terminal, writer, repo, argv) ⇒ Command
Returns a new instance of Command.
25 26 27 28 29 30 31 |
# File 'lib/rosette/client/commands.rb', line 25 def initialize(api, terminal, writer, repo, argv) @api = api @terminal = terminal @writer = writer @repo = repo @args = parse_args(argv) end |
Instance Attribute Details
#api ⇒ Object (readonly)
Returns the value of attribute api.
23 24 25 |
# File 'lib/rosette/client/commands.rb', line 23 def api @api end |
#args ⇒ Object (readonly)
Returns the value of attribute args.
23 24 25 |
# File 'lib/rosette/client/commands.rb', line 23 def args @args end |
#repo ⇒ Object (readonly)
Returns the value of attribute repo.
23 24 25 |
# File 'lib/rosette/client/commands.rb', line 23 def repo @repo end |
#terminal ⇒ Object (readonly)
Returns the value of attribute terminal.
23 24 25 |
# File 'lib/rosette/client/commands.rb', line 23 def terminal @terminal end |
#writer ⇒ Object (readonly)
Returns the value of attribute writer.
23 24 25 |
# File 'lib/rosette/client/commands.rb', line 23 def writer @writer end |