PlaceholderTextPart class
A PlaceholderPart implementation that represents literal, already-resolved text within a placeholder expression.
TextPart
is used for static text segments that require no further processing or resolution.
These parts are returned as-is during placeholder resolution. They typically appear in expressions like:
final part = TextPart('hello');
print(part.resolve(context)); // prints 'hello'
This class extends PlaceholderAbstractPart and simply returns the original text when resolved.
- Inheritance
-
- Object
- PlaceholderAbstractPart
- PlaceholderTextPart
Constructors
- PlaceholderTextPart(String text)
- A PlaceholderPart implementation that represents literal, already-resolved text within a placeholder expression.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
resolve(
PlaceholderPartResolutionContext resolutionContext) → String -
Represents a segment or fragment of a placeholder expression.
override
-
resolveRecursively(
PlaceholderPartResolutionContext resolutionContext, String key) → String? -
Recursively resolves the placeholder identified by
key
using the providedresolutionContext
.inherited -
text(
) → String -
Returns the raw textual representation of this part.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited