com.alibaba.dubbo.common.serialize.support.json
Class FastJsonObjectOutput

java.lang.Object
  extended by com.alibaba.dubbo.common.serialize.support.json.FastJsonObjectOutput
All Implemented Interfaces:
DataOutput, ObjectOutput

public class FastJsonObjectOutput
extends Object
implements ObjectOutput

JsonObjectOutput

Author:
william.liangf

Constructor Summary
FastJsonObjectOutput(OutputStream out)
           
FastJsonObjectOutput(Writer writer)
           
 
Method Summary
 void flushBuffer()
          Flush buffer.
 void writeBool(boolean v)
          Write boolean.
 void writeByte(byte v)
          Write byte.
 void writeBytes(byte[] b)
          Write byte array.
 void writeBytes(byte[] b, int off, int len)
          Write byte array.
 void writeDouble(double v)
          Write double.
 void writeFloat(float v)
          Write float.
 void writeInt(int v)
          Write integer.
 void writeLong(long v)
          Write long.
 void writeObject(Object obj)
          write object.
 void writeShort(short v)
          Write short.
 void writeUTF(String v)
          Write string.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FastJsonObjectOutput

public FastJsonObjectOutput(OutputStream out)

FastJsonObjectOutput

public FastJsonObjectOutput(Writer writer)
Method Detail

writeBool

public void writeBool(boolean v)
               throws IOException
Description copied from interface: DataOutput
Write boolean.

Specified by:
writeBool in interface DataOutput
Parameters:
v - value.
Throws:
IOException

writeByte

public void writeByte(byte v)
               throws IOException
Description copied from interface: DataOutput
Write byte.

Specified by:
writeByte in interface DataOutput
Parameters:
v - value.
Throws:
IOException

writeShort

public void writeShort(short v)
                throws IOException
Description copied from interface: DataOutput
Write short.

Specified by:
writeShort in interface DataOutput
Parameters:
v - value.
Throws:
IOException

writeInt

public void writeInt(int v)
              throws IOException
Description copied from interface: DataOutput
Write integer.

Specified by:
writeInt in interface DataOutput
Parameters:
v - value.
Throws:
IOException

writeLong

public void writeLong(long v)
               throws IOException
Description copied from interface: DataOutput
Write long.

Specified by:
writeLong in interface DataOutput
Parameters:
v - value.
Throws:
IOException

writeFloat

public void writeFloat(float v)
                throws IOException
Description copied from interface: DataOutput
Write float.

Specified by:
writeFloat in interface DataOutput
Parameters:
v - value.
Throws:
IOException

writeDouble

public void writeDouble(double v)
                 throws IOException
Description copied from interface: DataOutput
Write double.

Specified by:
writeDouble in interface DataOutput
Parameters:
v - value.
Throws:
IOException

writeUTF

public void writeUTF(String v)
              throws IOException
Description copied from interface: DataOutput
Write string.

Specified by:
writeUTF in interface DataOutput
Parameters:
v - value.
Throws:
IOException

writeBytes

public void writeBytes(byte[] b)
                throws IOException
Description copied from interface: DataOutput
Write byte array.

Specified by:
writeBytes in interface DataOutput
Parameters:
b - value.
Throws:
IOException

writeBytes

public void writeBytes(byte[] b,
                       int off,
                       int len)
                throws IOException
Description copied from interface: DataOutput
Write byte array.

Specified by:
writeBytes in interface DataOutput
Parameters:
b - value.
off - offset.
len - length.
Throws:
IOException

writeObject

public void writeObject(Object obj)
                 throws IOException
Description copied from interface: ObjectOutput
write object.

Specified by:
writeObject in interface ObjectOutput
Parameters:
obj - object.
Throws:
IOException

flushBuffer

public void flushBuffer()
                 throws IOException
Description copied from interface: DataOutput
Flush buffer.

Specified by:
flushBuffer in interface DataOutput
Throws:
IOException


Copyright © 2012–2017 Alibaba. All rights reserved.