NatrixTextFlag class final
Flag implementation for string values.
Accepts arbitrary text parameters such as file paths, names, or text literals.
The parse method handles escaped double quotes (\"), removing the escape
character while preserving the quote in the resulting value.
- Inheritance
-
- Object
- NatrixFlag<
String> - NatrixTextFlag
Constructors
- NatrixTextFlag({required String id, NatrixChar? acronym, String tooltip = "", String value = ""})
-
const
Properties
- acronym → NatrixChar?
-
Optional single-character shorthand for the flag, used as short-form
syntax in command-line arguments (
-awhereais the acronym character). Must be unique within a command's flag set.finalinherited -
examples
→ List<
String> -
Optional list of example values for help output generation.
finalinherited
- hasAcronym → bool
-
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
Unique identifier for the flag, used as long-form syntax in command-line
arguments (
--id).finalinherited - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- tooltip → String
-
Brief description displayed in help output.
finalinherited
- value → String
-
Current and/or initial value of the flag.
finalinherited
Methods
-
format(
String value) → String -
Formats a value of type
Tas a string for output or serialization.override -
getExamplesFormatted(
) → List< String> -
Returns formatted string representations of all examples.
inherited
-
getFormatted(
) → String -
Returns the formatted string representation of the current value.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
parse(
String raw) → String -
Parses a raw string from command-line arguments into type
T.override -
set(
String value) → NatrixFlag< String> -
Returns a new instance of this flag with the specified
value.override -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited