LiveCommandOption class
One option or flag a live command declares in its builder().
Constructors
-
LiveCommandOption({required String kind, required String name, String? abbr, String? help, List<
String> ? allowed, Object? defaultValue}) -
Creates a LiveCommandOption.
const
Properties
- abbr → String?
-
The single-letter abbreviation, used as
-a.final -
allowed
→ List<
String> ? -
Allowed values for an option.
final
- defaultValue → Object?
-
The default value: a
Stringfor options, aboolfor flags.final - hashCode → int
-
The hash code for this object.
no setterinherited
- help → String?
-
Help text shown in usage.
final
- isFlag → bool
-
Whether this entry is a boolean flag.
no setter
- kind → String
-
optionorflag.final - name → String
-
The long name, used as
--name.final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromJson(
Object? json) → LiveCommandOption? -
Parses one schema entry reported by
ext.nylo.commands.list.