IdentifierValue class final
Immutable domain value object representing a validated identifier.
- Inheritance
-
- Object
- ValueObject<
String> - IdentifierValue
- Annotations
-
- @immutable
Constructors
- IdentifierValue(String input, {IdentifierValidationConfig config = const IdentifierValidationConfig()})
-
Constructs an IdentifierValue from a trusted string.
Throws ValueObjectException if input is invalid.
factory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isSensitive → bool
-
Whether this value is sensitive (for example, a password).
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- value → String
-
The validated underlying value.
final
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
-
tryParse(
String input, {IdentifierValidationConfig config = const IdentifierValidationConfig()}) → Either< IdentifierError, IdentifierValue> -
Attempts to parse
inputinto an IdentifierValue. ReturnsEither<IdentifierError, IdentifierValue>.