JsonSceneRenderer class

JSON form of a scene with the same folding rule as the text renderer: a run's tail becomes one {"folded": {count, base, items}} entry.

Inheritance

Constructors

JsonSceneRenderer({bool pretty = true, int foldThreshold = 4})
const

Properties

foldThreshold → int
final
hashCode → int
The hash code for this object.
no setterinherited
pretty → bool
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

encode(Map<String, Object?> map) → String
nodeMap(SemanticNode n, {bool fold = true, int? maxDepth, int depth = 0}) → Map<String, Object?>
One node as a map, folding runs among its children.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
render(SemanticScene scene) → String
override
toMap(SemanticScene scene, {bool fold = true, int? maxDepth}) → Map<String, Object?>
The scene as a map; fold off = plain toJson. maxDepth drops children below that many levels (a childCount stands in).
toString() → String
A string representation of this object.
inherited

Operators

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