BoolOptions class

Options that control boolean parsing.

Annotations

Constructors

BoolOptions({Set<String> truthy = const {'true', '1', 'yes', 'y', 'on', 'ok', 't'}, Set<String> falsy = const {'false', '0', 'no', 'n', 'off', 'f'}, bool numericPositiveIsTrue = true})
Creates a new BoolOptions.
const

Properties

falsy Set<String>
A set of case-insensitive string tokens that resolve to false.
final
hashCode int
The hash code for this object.
no setterinherited
numericPositiveIsTrue bool
Determines how numeric values are converted to booleans.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
truthy Set<String>
A set of case-insensitive string tokens that resolve to true.
final

Methods

copyWith({Set<String>? truthy, Set<String>? falsy, bool? numericPositiveIsTrue}) BoolOptions
Returns a copy with selected fields replaced.
merge(BoolOptions other) BoolOptions
Returns a new BoolOptions that prefers other's settings.
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