org.yaml.snakeyaml.emitter.Emitable Java Examples
The following examples show how to use
org.yaml.snakeyaml.emitter.Emitable.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Serializer.java From Diorite with MIT License | 6 votes |
public Serializer(Serialization serialization, Emitable emitter, Resolver resolver, DumperOptions opts, @Nullable Tag rootTag) { this.serialization = serialization; this.emitter = EmitableWrapper.wrap(emitter); this.resolver = resolver; this.explicitStart = opts.isExplicitStart(); this.explicitEnd = opts.isExplicitEnd(); if (opts.getVersion() != null) { this.useVersion = opts.getVersion(); } this.useTags = opts.getTags(); this.serializedNodes = new HashSet<>(50); this.anchors = new HashMap<>(10); this.anchorGenerator = opts.getAnchorGenerator(); this.closed = null; this.explicitRoot = rootTag; }
Example #2
Source File: Serializer.java From orion.server with Eclipse Public License 1.0 | 5 votes |
public Serializer(Emitable emitter, Resolver resolver, DumperOptions opts, Tag rootTag) { this.emitter = emitter; this.resolver = resolver; this.explicitStart = opts.isExplicitStart(); this.explicitEnd = opts.isExplicitEnd(); if (opts.getVersion() != null) { this.useVersion = opts.getVersion(); } this.useTags = opts.getTags(); this.serializedNodes = new HashSet<Node>(); this.anchors = new HashMap<Node, String>(); this.lastAnchorId = 0; this.closed = null; this.explicitRoot = rootTag; }
Example #3
Source File: Serializer.java From snake-yaml with Apache License 2.0 | 5 votes |
public Serializer(Emitable emitter, Resolver resolver, DumperOptions opts, Tag rootTag) { this.emitter = emitter; this.resolver = resolver; this.explicitStart = opts.isExplicitStart(); this.explicitEnd = opts.isExplicitEnd(); if (opts.getVersion() != null) { this.useVersion = opts.getVersion(); } this.useTags = opts.getTags(); this.serializedNodes = new HashSet<Node>(); this.anchors = new HashMap<Node, String>(); this.anchorGenerator = opts.getAnchorGenerator(); this.closed = null; this.explicitRoot = rootTag; }
Example #4
Source File: EmitableWrapper.java From Diorite with MIT License | 5 votes |
static EmitableWrapper wrap(Emitable emitable) { if (emitable instanceof EmitableWrapper) { return (EmitableWrapper) emitable; } if (emitable instanceof Emitter) { return new EmitterWrapper((Emitter) emitable); } return new UnknownEmitableWrapper(emitable); }
Example #5
Source File: UnknownEmitableWrapper.java From Diorite with MIT License | 4 votes |
UnknownEmitableWrapper(Emitable emitable) { this.emitable = emitable; }