struct Tabular::Tablet
inherits Struct
#
Represents a parameter whose name and aliases may be suggested and matched during tab completion.
Constants#
Constructors#
.new(kind : Kind, name : String = "", aliases = [] of String, help = "", directives : Directable | Nil = nil, delimiters = Tabular.delimiters)
#
Create a new Tablet
.
- kind: See
#kind
. - name: See
#name
. - aliases: See
#aliases
. - help: See
#help
. - directives: See
#directives
. - delimiters: Ad hoc delimiters that will override [
Tabular.delimiters
][].
Methods#
#candidate(arg : String, & : String -> )
#
Yield suggestions for any names that contain arg.
#match!(arg : String)
#
Returns self
if arg is an exact match of any names. Otherwise, raise Error::Match
.