Exception: Cl::UnknownCmd

Inherits:
Error
  • Object
show all
Defined in:
lib/cl/errors.rb

Constant Summary

Constants inherited from Error

Error::MSGS

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(runner, args) ⇒ UnknownCmd

Returns a new instance of UnknownCmd.


32
33
34
35
36
# File 'lib/cl/errors.rb', line 32

def initialize(runner, args)
  @runner = runner
  @args = args
  super(:unknown_cmd, args.join(' '))
end

Instance Attribute Details

#argsObject (readonly)

Returns the value of attribute args


30
31
32
# File 'lib/cl/errors.rb', line 30

def args
  @args
end

#runnerObject (readonly)

Returns the value of attribute runner


30
31
32
# File 'lib/cl/errors.rb', line 30

def runner
  @runner
end

Instance Method Details

#suggestionsObject


38
39
40
# File 'lib/cl/errors.rb', line 38

def suggestions
  runner.suggestions(args)
end