public TokenBuffer(ObjectCodec paramObjectCodec) { this._objectCodec = paramObjectCodec; this._generatorFeatures = DEFAULT_PARSER_FEATURES; this._writeContext = JsonWriteContext.createRootContext(); Segment localSegment = new Segment(); this._last = localSegment; this._first = localSegment; this._appendOffset = 0; }
public final void writeEndArray() throws IOException, JsonGenerationException { _append(JsonToken.END_ARRAY); JsonWriteContext localJsonWriteContext = this._writeContext.getParent(); if (localJsonWriteContext != null) this._writeContext = localJsonWriteContext; }
public final void writeEndObject() throws IOException, JsonGenerationException { _append(JsonToken.END_OBJECT); JsonWriteContext localJsonWriteContext = this._writeContext.getParent(); if (localJsonWriteContext != null) this._writeContext = localJsonWriteContext; }
/** * @param codec Object codec to use for stream-based object * conversion through parser/generator interfaces. If null, * such methods can not be used. */ public TokenBuffer(ObjectCodec codec) { _objectCodec = codec; _generatorFeatures = DEFAULT_FEATURES; _writeContext = JsonWriteContext.createRootContext(); // at first we have just one segment _first = _last = new Segment(); _appendOffset = 0; }
@Override public final void writeEndArray() throws IOException, JsonGenerationException { _append(JsonToken.END_ARRAY); // Let's allow unbalanced tho... i.e. not run out of root level, ever JsonWriteContext c = _writeContext.getParent(); if (c != null) { _writeContext = c; } }
public final void writeEndObject() throws IOException, JsonGenerationException { _append(JsonToken.END_OBJECT); // Let's allow unbalanced tho... i.e. not run out of root level, ever JsonWriteContext c = _writeContext.getParent(); if (c != null) { _writeContext = c; } }
public TokenBuffer(ObjectCodec paramObjectCodec) { this._objectCodec = paramObjectCodec; this._generatorFeatures = DEFAULT_PARSER_FEATURES; this._writeContext = JsonWriteContext.createRootContext(); TokenBuffer.Segment localSegment = new TokenBuffer.Segment(); this._last = localSegment; this._first = localSegment; this._appendOffset = 0; }
public final void writeEndArray() { _append(JsonToken.END_ARRAY); JsonWriteContext localJsonWriteContext = this._writeContext.getParent(); if (localJsonWriteContext != null) this._writeContext = localJsonWriteContext; }
public final void writeEndObject() { _append(JsonToken.END_OBJECT); JsonWriteContext localJsonWriteContext = this._writeContext.getParent(); if (localJsonWriteContext != null) this._writeContext = localJsonWriteContext; }
public final JsonWriteContext getOutputContext() { return this._writeContext; }
public final JsonWriteContext getOutputContext() { return _writeContext; }