EditOp class sealed

One edit operation on a layout document, addressed by node id.

JSON: {"op": "set" | "patch" | "move" | "remove" | "vars" | "roots", ...}. decodeOps reads a batch; toJson writes one op.

Implementers
Annotations
  • @immutable

Properties

hashCode → int
The hash code for this object.
no setterinherited
op → String
The JSON op.
no setter
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
toJson() → Json
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

canonical(String? name) → String?
The op name means (set for set, Set and the alias add), or null when it names none.
fromJson(Object? json, {List<EditDiagnostic>? diagnostics}) → EditOp?
Decodes one op; null (with diagnostics saying why) when json is not one. A set with a nodes map is several ops: use decodeOps.
isOpName(String name) → bool
Whether name names an op (or an alias models write for one).
specOf(String op) → EditOpSpec?

Constants

specs → const List<EditOpSpec>
Every op's declaration, in the order the reference lists them.