Mapping class final Introduction YamlSourceNodes

A YAML Map which mirrors an actual Dart Map in equality and shape.

A mapping may allow a null key but it must be wrapped by a Scalar.

Inheritance
Implemented types
Available extensions

Constructors

Mapping(Map<Object?, Object?> base)

Properties

alias String?
Alias name that references other nodes.
no setter
anchor String?
Anchor name that allow other nodes to reference this node.
latefinal
childOfKey YamlSourceNode?
Always null unless this value is a key.
getter/setter pairoverride
children List<YamlSourceNode>
Childred if this is a collection.
final
entries Iterable<MapEntry<Object?, Object?>>
The map entries of this Map.
no setterinherited
hashCode int
The hash code for this object.
no setteroverride
isAlias bool
Whether the object is an alias.
no setteroverride
isCyclicRoot bool
Whether this is the first node in a cyclic linked-list.
getter/setter pairoverride
isEmpty bool
Whether there is no key/value pair in the map.
no setterinherited
isNotEmpty bool
Whether there is at least one key/value pair in the map.
no setterinherited
isTransversable bool
Whether the object is transversible by index/key or both. If true, this node is a collection.
no setteroverride
keys Iterable<Object?>
The keys of this Map.
no setterinherited
length int
The number of key/value pairs in the map.
no setterinherited
node Map<Object?, Object?>
Built-in or custom Dart type represented by this object.
no setteroverride
nodeStyle NodeStyle
Style used to serialize the node within the YAML source string
latefinal
parent YamlSourceNode?
Direct ancestor.
getter/setter pairoverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
siblingLeft YamlSourceNode?
Node on the left if in a collection.
getter/setter pairoverride
siblingRight YamlSourceNode?
Node on the right if in a collection.
getter/setter pairoverride
span NodeSpan
Span within a YAML source.
latefinaloverride-getter
tag ResolvedTag?
Tag directive describing how the node is represented natively.
latefinal
values Iterable<Object?>
The values of this Map.
no setterinherited

Methods

addAll(Map<Object?, Object?> other) → void
Adds all key/value pairs of other to this map.
inherited
addEntries(Iterable<MapEntry<Object?, Object?>> entries) → void
Adds all key/value pairs of newEntries to this map.
inherited
cast<RK, RV>() Map<RK, RV>
Provides a view of this map as having RK keys and RV instances, if necessary.
inherited
cast<T extends YamlSourceNode>() → T

Available on YamlSourceNode, provided by the Cast extension

Casts a generic YamlSourceNode to a valid (and known) subtype
clear() → void
Removes all entries from the map.
inherited
containsKey(Object? key) bool
Whether this map contains the given key.
inherited
containsValue(Object? value) bool
Whether this map contains the given value.
inherited
forEach(void action(Object? key, Object? value)) → void
Applies action to each key/value pair of the map.
inherited
map<K2, V2>(MapEntry<K2, V2> transform(Object? key, Object? value)) Map<K2, V2>
Returns a new map where all entries of this map are transformed by the given convert function.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
putIfAbsent(Object? key, Object? ifAbsent()) Object?
Look up the value of key, or add a new entry if it isn't there.
inherited
remove(Object? key) Object?
Removes key and its associated value, if present, from the map.
inherited
removeWhere(bool test(Object? key, Object? value)) → void
Removes all entries of this map that satisfy the given test.
inherited
toString() String
A string representation of this object.
inherited
update(Object? key, Object? update(Object? key), {Object? ifAbsent()?}) Object?
Updates the value for the provided key.
inherited
updateAll(Object? update(Object? key, Object? value)) → void
Updates all values.
inherited

Operators

operator ==(Object other) bool
The equality operator.
override
operator [](Object? key) Object?
The value for the given key, or null if key is not in the map.
inherited
operator []=(Object? key, Object? value) → void
Associates the key with the given value.
inherited