Class: Cliqr::Command::NumericArgumentOperator Private

Inherits:
ArgumentOperator show all
Defined in:
lib/cliqr/command/argument_operator.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Handle numerical arguments

Constant Summary

Constants inherited from ArgumentOperator

ArgumentOperator::DEFAULT_ARGUMENT_OPERATOR

Instance Method Summary collapse

Methods inherited from ArgumentOperator

for_type

Instance Method Details

#operate(value) ⇒ Integer

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Convert the argument to a integer value

Returns:

  • (Integer)


39
40
41
# File 'lib/cliqr/command/argument_operator.rb', line 39

def operate(value)
  value.to_i
end