public UnmanagedJsonParser(JsonOperationContext ctx, JsonParserState state, string debugTag)
 {
     _ctx                  = ctx;
     _state                = state;
     _debugTag             = debugTag;
     _unmanagedWriteBuffer = new UnmanagedWriteBuffer(ctx, ctx.GetMemory(1024 * 16));
 }
 public UnmanagedJsonParser(JsonOperationContext ctx, JsonParserState state, string debugTag)
 {
     _ctx                  = ctx;
     _state                = state;
     _debugTag             = debugTag;
     _unmanagedWriteBuffer = ctx.GetStream(JsonOperationContext.InitialStreamSize);
 }
 public UnmanagedJsonParser(JsonOperationContext ctx, JsonParserState state, string debugTag)
 {
     _ctx          = ctx;
     _state        = state;
     _debugTag     = debugTag;
     _stringBuffer = ctx.GetStream();
 }
        public void NewDocument()
        {
            _maybeBeforePreamble = true;
            var previous = _unmanagedWriteBuffer.SizeInBytes;

            _unmanagedWriteBuffer.Dispose();
            _unmanagedWriteBuffer = _ctx.GetStream(previous);
        }
Beispiel #5
0
 public void NewDocument()
 {
     _maybeBeforePreamble = true;
     _unmanagedWriteBuffer.Dispose();
     _unmanagedWriteBuffer = _ctx.GetStream();
 }
 public void SetStream()
 {
     _stringBuffer = _ctx.GetStream();
 }
 public void NewDocument()
 {
     _maybeBeforePreamble = true;
     _stringBuffer.Dispose();
     _stringBuffer = _ctx.GetStream();
 }