AFCommandArgumentsParsed class
Returned by AFCommandContext.parseArguments, the best way to access arguments from a command.
Used accessUnnamedFirst and accessNamed to easily access command arguments.
Constructors
-
AFCommandArgumentsParsed({required List<
String> unnamed, required Map<String, String?> named}) - AFCommandArgumentsParsed.empty()
-
factory
Properties
- accessUnnamedFirst → String
-
Accesses the first unnamed argument, which would typically be a class name.
no setter
- accessUnnamedSecond → String
-
no setter
- accessUnnamedThird → String
-
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
-
named
→ Map<
String, String?> -
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
unnamed
→ List<
String> -
final
Methods
-
accessNamed(
String name, {String? defaultVal}) → String - Accesses a named argument.
-
accessNamedFlag(
String name) → bool - Returns true if the specified named argument does not have the String value "false".
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
setIfNull(
String name, String value) → void -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited