JsonNullNode class
Represents a JSON null node (null) in the Dart JSON model.
This node indicates the absence of a value and behaves consistently with JsonNode type-checking methods.
Usage Example
final nullNode = JsonNullNode();
if (nullNode.isNull()) {
print(nullNode.toObject()); // null
}
Behavior Overview
| Dart JSON Value | Internal Representation | Description |
|---|---|---|
null |
JsonNullNode() |
Represents a null value |
Design Notes
Constructors
- JsonNullNode()
-
Represents a JSON null node (
null) in the Dart JSON model.const
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
-
isArray(
) → bool -
Returns
trueif this node represents a JSON array ([...]).override -
isBoolean(
) → bool -
Returns
trueif this node represents a JSON boolean (trueorfalse).override -
isNull(
) → bool -
Returns
trueif this node represents a JSONnull.override -
isNumber(
) → bool -
Returns
trueif this node represents a JSON number.override -
isObject(
) → bool -
Returns
trueif this node represents a JSON object ({...}).override -
isTextual(
) → bool -
Returns
trueif this node represents a JSON string.override -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toObject(
) → Object -
Generic interface representing a parsed node in Jetleaf's structured
data model (JSON/YAML/other).
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited