TextFlag class final

A flag that contains a String as it's value.

Inheritance

Constructors

TextFlag({required String name, String description = ""})

Properties

description String
Description of the flag, explaining the purpose of the property.
finalinherited
examples List<String>
The flags example values done for guiding.
finalinherited
format String Function(String value)
Formats the flags value into a string, that can be parsed by the Flag's parse function.
finalinherited
hashCode int
The hash code for this object.
no setterinherited
name String
The name of the flag, that have to be referenced when typing in the command line.
finalinherited
parse String Function(String raw)
Parses a string into the flags value type. Returns the parsed value.
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value String
The mutable reference to the flags value.
getter/setter pairinherited

Methods

getExamplesFormatted() List<String>
Returns the flag example values as formatted strings. If the examples are empty an empty list is returned.
inherited
getFormatted() String
Returns the flags value as a formatted string.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
setParsed(String raw) → void
Sets the parsed raw value as the flags one.
inherited
syntaxString() String
Syntax message part describing the flag.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited