Java 类org.codehaus.jackson.io.IOContext 实例源码

项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonGenerator createJsonGenerator(File paramFile, JsonEncoding paramJsonEncoding)
  throws IOException
{
  Object localObject = new FileOutputStream(paramFile);
  IOContext localIOContext = _createContext(localObject, true);
  localIOContext.setEncoding(paramJsonEncoding);
  if (paramJsonEncoding == JsonEncoding.UTF8)
  {
    if (this._outputDecorator != null)
      localObject = this._outputDecorator.decorate(localIOContext, (OutputStream)localObject);
    return _createUTF8JsonGenerator((OutputStream)localObject, localIOContext);
  }
  Writer localWriter = _createWriter((OutputStream)localObject, paramJsonEncoding, localIOContext);
  if (this._outputDecorator != null)
    localWriter = this._outputDecorator.decorate(localIOContext, localWriter);
  return (JsonGenerator)_createJsonGenerator(localWriter, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonGenerator createJsonGenerator(OutputStream paramOutputStream, JsonEncoding paramJsonEncoding)
  throws IOException
{
  IOContext localIOContext = _createContext(paramOutputStream, false);
  localIOContext.setEncoding(paramJsonEncoding);
  if (paramJsonEncoding == JsonEncoding.UTF8)
  {
    if (this._outputDecorator != null)
      paramOutputStream = this._outputDecorator.decorate(localIOContext, paramOutputStream);
    return _createUTF8JsonGenerator(paramOutputStream, localIOContext);
  }
  Writer localWriter = _createWriter(paramOutputStream, paramJsonEncoding, localIOContext);
  if (this._outputDecorator != null)
    localWriter = this._outputDecorator.decorate(localIOContext, localWriter);
  return _createJsonGenerator(localWriter, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonGenerator createJsonGenerator(File paramFile, JsonEncoding paramJsonEncoding)
  throws IOException
{
  Object localObject = new FileOutputStream(paramFile);
  IOContext localIOContext = _createContext(localObject, true);
  localIOContext.setEncoding(paramJsonEncoding);
  if (paramJsonEncoding == JsonEncoding.UTF8)
  {
    if (this._outputDecorator != null)
      localObject = this._outputDecorator.decorate(localIOContext, (OutputStream)localObject);
    return _createUTF8JsonGenerator((OutputStream)localObject, localIOContext);
  }
  Writer localWriter = _createWriter((OutputStream)localObject, paramJsonEncoding, localIOContext);
  if (this._outputDecorator != null)
    localWriter = this._outputDecorator.decorate(localIOContext, localWriter);
  return (JsonGenerator)_createJsonGenerator(localWriter, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonGenerator createJsonGenerator(OutputStream paramOutputStream, JsonEncoding paramJsonEncoding)
  throws IOException
{
  IOContext localIOContext = _createContext(paramOutputStream, false);
  localIOContext.setEncoding(paramJsonEncoding);
  if (paramJsonEncoding == JsonEncoding.UTF8)
  {
    if (this._outputDecorator != null)
      paramOutputStream = this._outputDecorator.decorate(localIOContext, paramOutputStream);
    return _createUTF8JsonGenerator(paramOutputStream, localIOContext);
  }
  Writer localWriter = _createWriter(paramOutputStream, paramJsonEncoding, localIOContext);
  if (this._outputDecorator != null)
    localWriter = this._outputDecorator.decorate(localIOContext, localWriter);
  return _createJsonGenerator(localWriter, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
protected JsonGenerator _createJsonGenerator(Writer paramWriter, IOContext paramIOContext)
  throws IOException
{
  WriterBasedGenerator localWriterBasedGenerator = new WriterBasedGenerator(paramIOContext, this._generatorFeatures, this._objectCodec, paramWriter);
  if (this._characterEscapes != null)
    localWriterBasedGenerator.setCharacterEscapes(this._characterEscapes);
  return localWriterBasedGenerator;
}
项目:12306-android-Decompile    文件:JsonFactory.java   
protected JsonGenerator _createUTF8JsonGenerator(OutputStream paramOutputStream, IOContext paramIOContext)
  throws IOException
{
  Utf8Generator localUtf8Generator = new Utf8Generator(paramIOContext, this._generatorFeatures, this._objectCodec, paramOutputStream);
  if (this._characterEscapes != null)
    localUtf8Generator.setCharacterEscapes(this._characterEscapes);
  return localUtf8Generator;
}
项目:12306-android-Decompile    文件:JsonFactory.java   
protected Writer _createWriter(OutputStream paramOutputStream, JsonEncoding paramJsonEncoding, IOContext paramIOContext)
  throws IOException
{
  if (paramJsonEncoding == JsonEncoding.UTF8)
    return new UTF8Writer(paramIOContext, paramOutputStream);
  return new OutputStreamWriter(paramOutputStream, paramJsonEncoding.getJavaName());
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonGenerator createJsonGenerator(Writer paramWriter)
  throws IOException
{
  IOContext localIOContext = _createContext(paramWriter, false);
  if (this._outputDecorator != null)
    paramWriter = this._outputDecorator.decorate(localIOContext, paramWriter);
  return _createJsonGenerator(paramWriter, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(File paramFile)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramFile, true);
  Object localObject = new FileInputStream(paramFile);
  if (this._inputDecorator != null)
    localObject = this._inputDecorator.decorate(localIOContext, (InputStream)localObject);
  return (JsonParser)_createJsonParser((InputStream)localObject, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(InputStream paramInputStream)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramInputStream, false);
  if (this._inputDecorator != null)
    paramInputStream = this._inputDecorator.decorate(localIOContext, paramInputStream);
  return _createJsonParser(paramInputStream, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(Reader paramReader)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramReader, false);
  if (this._inputDecorator != null)
    paramReader = this._inputDecorator.decorate(localIOContext, paramReader);
  return _createJsonParser(paramReader, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(String paramString)
  throws IOException, JsonParseException
{
  Object localObject = new StringReader(paramString);
  IOContext localIOContext = _createContext(localObject, true);
  if (this._inputDecorator != null)
    localObject = this._inputDecorator.decorate(localIOContext, (Reader)localObject);
  return (JsonParser)_createJsonParser((Reader)localObject, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(URL paramURL)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramURL, true);
  InputStream localInputStream = _optimizedStreamFromURL(paramURL);
  if (this._inputDecorator != null)
    localInputStream = this._inputDecorator.decorate(localIOContext, localInputStream);
  return _createJsonParser(localInputStream, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(byte[] paramArrayOfByte)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramArrayOfByte, true);
  if (this._inputDecorator != null)
  {
    InputStream localInputStream = this._inputDecorator.decorate(localIOContext, paramArrayOfByte, 0, paramArrayOfByte.length);
    if (localInputStream != null)
      return _createJsonParser(localInputStream, localIOContext);
  }
  return _createJsonParser(paramArrayOfByte, 0, paramArrayOfByte.length, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(byte[] paramArrayOfByte, int paramInt1, int paramInt2)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramArrayOfByte, true);
  if (this._inputDecorator != null)
  {
    InputStream localInputStream = this._inputDecorator.decorate(localIOContext, paramArrayOfByte, paramInt1, paramInt2);
    if (localInputStream != null)
      return _createJsonParser(localInputStream, localIOContext);
  }
  return _createJsonParser(paramArrayOfByte, paramInt1, paramInt2, localIOContext);
}
项目:12306-android-Decompile    文件:JsonParserBase.java   
protected JsonParserBase(IOContext paramIOContext, int paramInt)
{
  this._features = paramInt;
  this._ioContext = paramIOContext;
  this._textBuffer = paramIOContext.constructTextBuffer();
  this._parsingContext = JsonReadContext.createRootContext(this._tokenInputRow, this._tokenInputCol);
}
项目:12306-android-Decompile    文件:Utf8StreamParser.java   
public Utf8StreamParser(IOContext paramIOContext, int paramInt1, InputStream paramInputStream, ObjectCodec paramObjectCodec, BytesToNameCanonicalizer paramBytesToNameCanonicalizer, byte[] paramArrayOfByte, int paramInt2, int paramInt3, boolean paramBoolean)
{
  super(paramIOContext, paramInt1, paramInputStream, paramArrayOfByte, paramInt2, paramInt3, paramBoolean);
  this._objectCodec = paramObjectCodec;
  this._symbols = paramBytesToNameCanonicalizer;
  if (!JsonParser.Feature.CANONICALIZE_FIELD_NAMES.enabledIn(paramInt1))
    _throwInternal();
}
项目:12306-android-Decompile    文件:ByteSourceBootstrapper.java   
public ByteSourceBootstrapper(IOContext paramIOContext, InputStream paramInputStream)
{
  this._context = paramIOContext;
  this._in = paramInputStream;
  this._inputBuffer = paramIOContext.allocReadIOBuffer();
  this._inputPtr = 0;
  this._inputEnd = 0;
  this._inputProcessed = 0;
  this._bufferRecyclable = true;
}
项目:12306-android-Decompile    文件:ByteSourceBootstrapper.java   
public ByteSourceBootstrapper(IOContext paramIOContext, byte[] paramArrayOfByte, int paramInt1, int paramInt2)
{
  this._context = paramIOContext;
  this._in = null;
  this._inputBuffer = paramArrayOfByte;
  this._inputPtr = paramInt1;
  this._inputEnd = (paramInt1 + paramInt2);
  this._inputProcessed = (-paramInt1);
  this._bufferRecyclable = false;
}
项目:12306-android-Decompile    文件:WriterBasedGenerator.java   
public WriterBasedGenerator(IOContext paramIOContext, int paramInt, ObjectCodec paramObjectCodec, Writer paramWriter)
{
  super(paramInt, paramObjectCodec);
  this._ioContext = paramIOContext;
  this._writer = paramWriter;
  this._outputBuffer = paramIOContext.allocConcatBuffer();
  this._outputEnd = this._outputBuffer.length;
  if (isEnabled(JsonGenerator.Feature.ESCAPE_NON_ASCII))
    setHighestNonEscapedChar(127);
}
项目:12306-android-Decompile    文件:Utf8Generator.java   
public Utf8Generator(IOContext paramIOContext, int paramInt, ObjectCodec paramObjectCodec, OutputStream paramOutputStream)
{
  super(paramInt, paramObjectCodec);
  this._ioContext = paramIOContext;
  this._outputStream = paramOutputStream;
  this._bufferRecyclable = true;
  this._outputBuffer = paramIOContext.allocWriteEncodingBuffer();
  this._outputEnd = this._outputBuffer.length;
  this._outputMaxContiguous = (this._outputEnd >> 3);
  this._charBuffer = paramIOContext.allocConcatBuffer();
  this._charBufferLength = this._charBuffer.length;
  if (isEnabled(JsonGenerator.Feature.ESCAPE_NON_ASCII))
    setHighestNonEscapedChar(127);
}
项目:12306-android-Decompile    文件:Utf8Generator.java   
public Utf8Generator(IOContext paramIOContext, int paramInt1, ObjectCodec paramObjectCodec, OutputStream paramOutputStream, byte[] paramArrayOfByte, int paramInt2, boolean paramBoolean)
{
  super(paramInt1, paramObjectCodec);
  this._ioContext = paramIOContext;
  this._outputStream = paramOutputStream;
  this._bufferRecyclable = paramBoolean;
  this._outputTail = paramInt2;
  this._outputBuffer = paramArrayOfByte;
  this._outputEnd = this._outputBuffer.length;
  this._outputMaxContiguous = (this._outputEnd >> 3);
  this._charBuffer = paramIOContext.allocConcatBuffer();
  this._charBufferLength = this._charBuffer.length;
  if (isEnabled(JsonGenerator.Feature.ESCAPE_NON_ASCII))
    setHighestNonEscapedChar(127);
}
项目:12306-android-Decompile    文件:StreamBasedParserBase.java   
protected StreamBasedParserBase(IOContext paramIOContext, int paramInt1, InputStream paramInputStream, byte[] paramArrayOfByte, int paramInt2, int paramInt3, boolean paramBoolean)
{
  super(paramIOContext, paramInt1);
  this._inputStream = paramInputStream;
  this._inputBuffer = paramArrayOfByte;
  this._inputPtr = paramInt2;
  this._inputEnd = paramInt3;
  this._bufferRecyclable = paramBoolean;
}
项目:RHome    文件:ReaderBasedParser.java   
public ReaderBasedParser(IOContext ioCtxt, int features, Reader r,
                         ObjectCodec codec, CharsToNameCanonicalizer st)
{
    super(ioCtxt, features, r);
    _objectCodec = codec;
    _symbols = st;
}
项目:RHome    文件:JsonParserBase.java   
protected JsonParserBase(IOContext ctxt, int features)
{
    _ioContext = ctxt;
    _features = features;
    _textBuffer = ctxt.constructTextBuffer();
    _parsingContext = JsonReadContext.createRootContext(_tokenInputRow, _tokenInputCol);
}
项目:RHome    文件:Utf8StreamParser.java   
public Utf8StreamParser(IOContext ctxt, int features, InputStream in,
                        ObjectCodec codec,
                        BytesToNameCanonicalizer sym,
                        byte[] inputBuffer, int start, int end,
                        boolean bufferRecyclable)
{
    super(ctxt, features, in, inputBuffer, start, end, bufferRecyclable);
    _objectCodec = codec;
    _symbols = sym;
    // 12-Mar-2010, tatus: Sanity check, related to [JACKSON-259]:
    if (!JsonParser.Feature.CANONICALIZE_FIELD_NAMES.enabledIn(features)) {
        // should never construct non-canonical utf8/byte parser (instead, use Reader)
        _throwInternal();
    }
}
项目:RHome    文件:Utf8NumericParser.java   
public Utf8NumericParser(IOContext pc, int features,
                         InputStream in,
                         byte[] inputBuffer, int start, int end,
                         boolean bufferRecyclable)
{
    super(pc, features, in, inputBuffer, start, end, bufferRecyclable);
}
项目:RHome    文件:StreamBasedParserBase.java   
protected StreamBasedParserBase(IOContext ctxt, int features,
                                InputStream in,
                                byte[] inputBuffer, int start, int end,
                                boolean bufferRecyclable)
{
    super(ctxt, features);
    _inputStream = in;
    _inputBuffer = inputBuffer;
    _inputPtr = start;
    _inputEnd = end;
    _bufferRecyclable = bufferRecyclable;
}
项目:12306-android-Decompile    文件:JsonFactory.java   
protected JsonGenerator _createJsonGenerator(Writer paramWriter, IOContext paramIOContext)
  throws IOException
{
  WriterBasedGenerator localWriterBasedGenerator = new WriterBasedGenerator(paramIOContext, this._generatorFeatures, this._objectCodec, paramWriter);
  if (this._characterEscapes != null)
    localWriterBasedGenerator.setCharacterEscapes(this._characterEscapes);
  return localWriterBasedGenerator;
}
项目:12306-android-Decompile    文件:JsonFactory.java   
protected JsonGenerator _createUTF8JsonGenerator(OutputStream paramOutputStream, IOContext paramIOContext)
  throws IOException
{
  Utf8Generator localUtf8Generator = new Utf8Generator(paramIOContext, this._generatorFeatures, this._objectCodec, paramOutputStream);
  if (this._characterEscapes != null)
    localUtf8Generator.setCharacterEscapes(this._characterEscapes);
  return localUtf8Generator;
}
项目:12306-android-Decompile    文件:JsonFactory.java   
protected Writer _createWriter(OutputStream paramOutputStream, JsonEncoding paramJsonEncoding, IOContext paramIOContext)
  throws IOException
{
  if (paramJsonEncoding == JsonEncoding.UTF8)
    return new UTF8Writer(paramIOContext, paramOutputStream);
  return new OutputStreamWriter(paramOutputStream, paramJsonEncoding.getJavaName());
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonGenerator createJsonGenerator(Writer paramWriter)
  throws IOException
{
  IOContext localIOContext = _createContext(paramWriter, false);
  if (this._outputDecorator != null)
    paramWriter = this._outputDecorator.decorate(localIOContext, paramWriter);
  return _createJsonGenerator(paramWriter, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(File paramFile)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramFile, true);
  Object localObject = new FileInputStream(paramFile);
  if (this._inputDecorator != null)
    localObject = this._inputDecorator.decorate(localIOContext, (InputStream)localObject);
  return (JsonParser)_createJsonParser((InputStream)localObject, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(InputStream paramInputStream)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramInputStream, false);
  if (this._inputDecorator != null)
    paramInputStream = this._inputDecorator.decorate(localIOContext, paramInputStream);
  return _createJsonParser(paramInputStream, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(Reader paramReader)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramReader, false);
  if (this._inputDecorator != null)
    paramReader = this._inputDecorator.decorate(localIOContext, paramReader);
  return _createJsonParser(paramReader, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(String paramString)
  throws IOException, JsonParseException
{
  Object localObject = new StringReader(paramString);
  IOContext localIOContext = _createContext(localObject, true);
  if (this._inputDecorator != null)
    localObject = this._inputDecorator.decorate(localIOContext, (Reader)localObject);
  return (JsonParser)_createJsonParser((Reader)localObject, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(URL paramURL)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramURL, true);
  InputStream localInputStream = _optimizedStreamFromURL(paramURL);
  if (this._inputDecorator != null)
    localInputStream = this._inputDecorator.decorate(localIOContext, localInputStream);
  return _createJsonParser(localInputStream, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(byte[] paramArrayOfByte)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramArrayOfByte, true);
  if (this._inputDecorator != null)
  {
    InputStream localInputStream = this._inputDecorator.decorate(localIOContext, paramArrayOfByte, 0, paramArrayOfByte.length);
    if (localInputStream != null)
      return _createJsonParser(localInputStream, localIOContext);
  }
  return _createJsonParser(paramArrayOfByte, 0, paramArrayOfByte.length, localIOContext);
}
项目:12306-android-Decompile    文件:JsonFactory.java   
public JsonParser createJsonParser(byte[] paramArrayOfByte, int paramInt1, int paramInt2)
  throws IOException, JsonParseException
{
  IOContext localIOContext = _createContext(paramArrayOfByte, true);
  if (this._inputDecorator != null)
  {
    InputStream localInputStream = this._inputDecorator.decorate(localIOContext, paramArrayOfByte, paramInt1, paramInt2);
    if (localInputStream != null)
      return _createJsonParser(localInputStream, localIOContext);
  }
  return _createJsonParser(paramArrayOfByte, paramInt1, paramInt2, localIOContext);
}
项目:12306-android-Decompile    文件:JsonParserBase.java   
protected JsonParserBase(IOContext paramIOContext, int paramInt)
{
  this._features = paramInt;
  this._ioContext = paramIOContext;
  this._textBuffer = paramIOContext.constructTextBuffer();
  this._parsingContext = JsonReadContext.createRootContext(this._tokenInputRow, this._tokenInputCol);
}