Exception: Rubikon::UnknownCommandError

Inherits:
ArgumentError
  • Object
show all
Defined in:
lib/rubikon/errors.rb

Overview

Raised if a command has been supplied that does not exist

See Also:

Author:

  • Sebastian Staudt

Since:

  • 0.3.0

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name) ⇒ UnknownCommandError

Creates a new error and stores the name of the command that could not be found

Parameters:

  • name (Symbol)

    The name of the unknown command

Since:

  • 0.3.0



72
73
74
75
# File 'lib/rubikon/errors.rb', line 72

def initialize(name)
  super "Unknown command: #{name}"
  @command = name
end

Instance Attribute Details

#commandSymbol (readonly)

Returns The name of the command that has been tried to access.

Returns:

  • (Symbol)

    The name of the command that has been tried to access

Since:

  • 0.3.0



66
67
68
# File 'lib/rubikon/errors.rb', line 66

def command
  @command
end