class RemiLib::Args::IntArgument

Overview

An Argument that expects an integer. This always stores its value as an Int64.

Included Modules

Defined in:

remilib/args/arg-types.cr

Instance Method Summary

Instance methods inherited from module RemiLib::Args::ValArgument

setValue!(val) : Nil setValue!, value value, value=(val) : Nil value=

Instance methods inherited from class RemiLib::Args::Argument

callback : ArgCallbackFunc | Nil callback, callback=(callback : ArgCallbackFunc | Nil) callback=, called? : Bool called?, group : String group, group=(group : String) group=, help : String help, help=(help : String) help=, longName : String longName, longName=(newName : String) : Nil longName=, shortName : Char | Nil shortName, shortName=(shortName : Char | Nil) shortName=

Constructor methods inherited from class RemiLib::Args::Argument

new(newLongName, shortName : Char | Nil = nil, group : String = "", help : String = "") new

Instance Method Detail

def maximum : Int64 #

The maximum accepted value for this argument.


[View source]
def maximum=(maximum : Int64) #

The maximum accepted value for this argument.


[View source]
def minimum : Int64 #

The minimum accepted value for this argument.


[View source]
def minimum=(minimum : Int64) #

The minimum accepted value for this argument.


[View source]
def setValue!(val : Int64) : Nil #

Sets the value of the argument. This does not set #called? to true, and does not check the #minimum and #maximum.


[View source]
def setValue!(val) : Nil #

Sets the value of the argument. This does not set #called? to true, and does not check the #minimum and #maximum.

val must respond to #to_i64.


[View source]
def str : String #

Returns the value of this argument as a string.


[View source]
def value : Int64 #

Returns the value of this argument.


[View source]
def value=(val : Int64) : Nil #

Sets the value of the argument. This is checked against the #minimum and #maximum. This sets #called? to true.


[View source]
def value=(val) : Nil #

Sets the value of the argument. This is checked against the #minimum and #maximum. This sets #called? to true.

newVal must respond to #to_i64.


[View source]