class
RemiLib::Args::StringArgument
Overview
An Argument that expects some sort of string value.
Included Modules
Defined in:
remilib/args/arg-types.crInstance Method Summary
-
#oneOf : Array(String)
A list of values that the argument is allowed to take.
-
#oneOf=(oneOf : Array(String))
A list of values that the argument is allowed to take.
-
#setValue!(val : String) : Nil
Sets the value of the argument.
-
#setValue!(val) : Nil
:inherit:
-
#str : String
Returns the value of the argument.
-
#value : String
Returns the value of the argument.
-
#value=(val : String)
Sets the value of the argument.
-
#value=(val) : Nil
Sets the value of the argument.
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 methods inherited from class Object
toRsconf(io : IO, *, indentSize : Int = 2, alwaysQuoteKeys : Bool = false, explicitRootObject : Bool = false, commaAfterValues : Bool = false, extraNewlineBetweenToplevelKeys : Bool = false) : NiltoRsconf(*, indentSize : Int = 2, alwaysQuoteKeys : Bool = false, explicitRootObject : Bool = false, commaAfterValues : Bool = false, extraNewlineBetweenToplevelKeys : Bool = false) : String toRsconf
Class methods inherited from class Object
fromRsconf(toplevel : RemiLib::RSConf::RSValue)fromRsconf(data : String | IO | Path) fromRsconf
Instance Method Detail
A list of values that the argument is allowed to take. If the
user provides a value that does not match any of these, an
ArgumentError is raised during parsing.
A list of values that the argument is allowed to take. If the
user provides a value that does not match any of these, an
ArgumentError is raised during parsing.
Sets the value of the argument. This does not set #called? to true,
and does not check #oneOf.
Returns the value of the argument. This is interchangeable with #value
for the StringArgument class.
Sets the value of the argument. This also sets #called? to true.
Sets the value of the argument. This also sets #called? to true.