/** * Overridable factory method that actually instantiates desired * parser. */ @Override protected CBORParser _createParser(byte[] data, int offset, int len, IOContext ctxt) throws IOException { return new CBORParserBootstrapper(ctxt, data, offset, len).constructParser( _factoryFeatures, _parserFeatures, _formatParserFeatures, _objectCodec, _byteSymbolCanonicalizer); }
@Override public MatchStrength hasFormat(InputAccessor acc) throws IOException { return CBORParserBootstrapper.hasCBORFormat(acc); }
public CBORParser constructParser(int factoryFeatures, int generalParserFeatures, int formatFeatures, ObjectCodec codec, ByteQuadsCanonicalizer rootByteSymbols) throws IOException, JsonParseException { ByteQuadsCanonicalizer can = rootByteSymbols.makeChild(factoryFeatures); // We just need a single byte to recognize possible "empty" document. ensureLoaded(1); CBORParser p = new CBORParser(_context, generalParserFeatures, formatFeatures, codec, can, _in, _inputBuffer, _inputPtr, _inputEnd, _bufferRecyclable); if (_inputPtr < _inputEnd) { // only false for empty doc ; // anything we should verify? In future, could verify } else { /* 13-Jan-2014, tatu: Actually, let's allow empty documents even if * header signature would otherwise be needed. This is useful for * JAX-RS provider, empty PUT/POST payloads? */ ; } return p; }
public CBORParser constructParser(int factoryFeatures, int generalParserFeatures, int formatFeatures, ObjectCodec codec, ByteQuadsCanonicalizer rootByteSymbols) throws IOException, JsonParseException { ByteQuadsCanonicalizer can = rootByteSymbols.makeChild(factoryFeatures); // We just need a single byte to recognize possible "empty" document. ensureLoaded(1); CBORParser p = new CBORParser(_context, generalParserFeatures, formatFeatures, codec, can, _in, _inputBuffer, _inputPtr, _inputEnd, _bufferRecyclable); if (_inputPtr < _inputEnd) { // only false for empty doc ; // anything we should verify? In future, could verify } else { /* 13-Jan-2014, tatu: Actually, let's allow empty documents even if * header signature would otherwise be needed. This is useful for * JAX-RS provider, empty PUT/POST payloads? */ ; } return p; }
/** * Overridable factory method that actually instantiates desired * parser. */ @Override protected CBORParser _createParser(InputStream in, IOContext ctxt) throws IOException { return new CBORParserBootstrapper(ctxt, in).constructParser(_factoryFeatures, _parserFeatures, _formatParserFeatures, _objectCodec, _byteSymbolCanonicalizer); }
@Override public MatchStrength hasFormat(InputAccessor acc) throws IOException { return CBORParserBootstrapper.hasCBORFormat(acc); }
public CBORParser constructParser(int factoryFeatures, int generalParserFeatures, int formatFeatures, ObjectCodec codec, ByteQuadsCanonicalizer rootByteSymbols) throws IOException, JsonParseException { ByteQuadsCanonicalizer can = rootByteSymbols.makeChild(factoryFeatures); // We just need a single byte to recognize possible "empty" document. ensureLoaded(1); CBORParser p = new CBORParser(_context, generalParserFeatures, formatFeatures, codec, can, _in, _inputBuffer, _inputPtr, _inputEnd, _bufferRecyclable); if (_inputPtr < _inputEnd) { // only false for empty doc ; // anything we should verify? In future, could verify } else { /* 13-Jan-2014, tatu: Actually, let's allow empty documents even if * header signature would otherwise be needed. This is useful for * JAX-RS provider, empty PUT/POST payloads? */ ; } return p; }
/** * Overridable factory method that actually instantiates desired * parser. */ @Override protected CBORParser _createParser(InputStream in, IOContext ctxt) throws IOException { return new CBORParserBootstrapper(ctxt, in).constructParser(_factoryFeatures, _parserFeatures, _formatParserFeatures, _objectCodec, _byteSymbolCanonicalizer); }
@Override public MatchStrength hasFormat(InputAccessor acc) throws IOException { return CBORParserBootstrapper.hasCBORFormat(acc); }
/** * Overridable factory method that actually instantiates desired * parser. */ @Override protected CBORParser _createParser(InputStream in, IOContext ctxt) throws IOException { return new CBORParserBootstrapper(ctxt, in).constructParser(_factoryFeatures, _parserFeatures, _formatParserFeatures, _objectCodec, _byteSymbolCanonicalizer); }
/** * Overridable factory method that actually instantiates desired * parser. */ @Override protected CBORParser _createParser(byte[] data, int offset, int len, IOContext ctxt) throws IOException { return new CBORParserBootstrapper(ctxt, data, offset, len).constructParser( _factoryFeatures, _parserFeatures, _formatParserFeatures, _objectCodec, _byteSymbolCanonicalizer); }
/** * Overridable factory method that actually instantiates desired * parser. */ @Override protected CBORParser _createParser(byte[] data, int offset, int len, IOContext ctxt) throws IOException { return new CBORParserBootstrapper(ctxt, data, offset, len).constructParser( _factoryFeatures, _parserFeatures, _formatParserFeatures, _objectCodec, _byteSymbolCanonicalizer); }