| java.lang.Object com.caucho.hessian.io.AbstractHessianOutput com.caucho.hessian.io.HessianOutput com.caucho.hessian.io.HessianSerializerOutput
HessianSerializerOutput | public class HessianSerializerOutput extends HessianOutput (Code) | | Output stream for Hessian requests.
HessianOutput is unbuffered, so any client needs to provide
its own buffering.
Serialization
OutputStream os = new FileOutputStream("test.xml");
HessianOutput out = new HessianSerializerOutput(os);
out.writeObject(obj);
os.close();
Writing an RPC Call
OutputStream os = ...; // from http connection
HessianOutput out = new HessianSerializerOutput(os);
String value;
out.startCall("hello"); // start hello call
out.writeString("arg1"); // write a string argument
out.completeCall(); // complete the call
|
Method Summary | |
public void | writeObjectImpl(Object obj) Applications which override this can do custom serialization. |
HessianSerializerOutput | public HessianSerializerOutput(OutputStream os)(Code) | | Creates a new Hessian output stream, initialized with an
underlying output stream.
Parameters: os - the underlying output stream. |
HessianSerializerOutput | public HessianSerializerOutput()(Code) | | Creates an uninitialized Hessian output stream.
|
writeObjectImpl | public void writeObjectImpl(Object obj) throws IOException(Code) | | Applications which override this can do custom serialization.
Parameters: object - the object to write. |
Methods inherited from com.caucho.hessian.io.HessianOutput | public boolean addRef(Object object) throws IOException(Code)(Java Doc) public void call(String method, Object[] args) throws IOException(Code)(Java Doc) public void completeCall() throws IOException(Code)(Java Doc) public void completeReply() throws IOException(Code)(Java Doc) public void init(OutputStream os)(Code)(Java Doc) public void printLenString(String v) throws IOException(Code)(Java Doc) public void printString(String v) throws IOException(Code)(Java Doc) public void printString(String v, int offset, int length) throws IOException(Code)(Java Doc) public void printString(char[] v, int offset, int length) throws IOException(Code)(Java Doc) public boolean removeRef(Object obj) throws IOException(Code)(Java Doc) public boolean replaceRef(Object oldRef, Object newRef) throws IOException(Code)(Java Doc) public void resetReferences()(Code)(Java Doc) public void setVersion(int version)(Code)(Java Doc) public void startCall(String method) throws IOException(Code)(Java Doc) public void startCall() throws IOException(Code)(Java Doc) public void startReply() throws IOException(Code)(Java Doc) public void writeBoolean(boolean value) throws IOException(Code)(Java Doc) public void writeByteBufferEnd(byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeByteBufferPart(byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeByteBufferStart() throws IOException(Code)(Java Doc) public void writeBytes(byte[] buffer) throws IOException(Code)(Java Doc) public void writeBytes(byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeDouble(double value) throws IOException(Code)(Java Doc) public void writeFault(String code, String message, Object detail) throws IOException(Code)(Java Doc) public void writeHeader(String name) throws IOException(Code)(Java Doc) public void writeInt(int value) throws IOException(Code)(Java Doc) public boolean writeListBegin(int length, String type) throws IOException(Code)(Java Doc) public void writeListEnd() throws IOException(Code)(Java Doc) public void writeLong(long value) throws IOException(Code)(Java Doc) public void writeMapBegin(String type) throws IOException(Code)(Java Doc) public void writeMapEnd() throws IOException(Code)(Java Doc) public void writeMethod(String method) throws IOException(Code)(Java Doc) public void writeNull() throws IOException(Code)(Java Doc) public void writeObject(Object object) throws IOException(Code)(Java Doc) public void writePlaceholder() throws IOException(Code)(Java Doc) public void writeRef(int value) throws IOException(Code)(Java Doc) public void writeRemote(String type, String url) throws IOException(Code)(Java Doc) public void writeString(String value) throws IOException(Code)(Java Doc) public void writeString(char[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeUTCDate(long time) throws IOException(Code)(Java Doc)
|
Methods inherited from com.caucho.hessian.io.AbstractHessianOutput | abstract public boolean addRef(Object object) throws IOException(Code)(Java Doc) public void call(String method, Object[] args) throws IOException(Code)(Java Doc) public void close() throws IOException(Code)(Java Doc) abstract public void completeCall() throws IOException(Code)(Java Doc) public void completeReply() throws IOException(Code)(Java Doc) final public SerializerFactory findSerializerFactory()(Code)(Java Doc) public void flush() throws IOException(Code)(Java Doc) public SerializerFactory getSerializerFactory()(Code)(Java Doc) public void init(OutputStream os)(Code)(Java Doc) abstract public boolean removeRef(Object obj) throws IOException(Code)(Java Doc) abstract public boolean replaceRef(Object oldRef, Object newRef) throws IOException(Code)(Java Doc) public void resetReferences()(Code)(Java Doc) public void setSerializerFactory(SerializerFactory factory)(Code)(Java Doc) abstract public void startCall() throws IOException(Code)(Java Doc) abstract public void startCall(String method) throws IOException(Code)(Java Doc) public void startReply() throws IOException(Code)(Java Doc) abstract public void writeBoolean(boolean value) throws IOException(Code)(Java Doc) abstract public void writeByteBufferEnd(byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) abstract public void writeByteBufferPart(byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) abstract public void writeByteBufferStart() throws IOException(Code)(Java Doc) abstract public void writeBytes(byte[] buffer) throws IOException(Code)(Java Doc) abstract public void writeBytes(byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeClassFieldLength(int len) throws IOException(Code)(Java Doc) abstract public void writeDouble(double value) throws IOException(Code)(Java Doc) public void writeFault(String code, String message, Object detail) throws IOException(Code)(Java Doc) abstract public void writeHeader(String name) throws IOException(Code)(Java Doc) abstract public void writeInt(int value) throws IOException(Code)(Java Doc) abstract public boolean writeListBegin(int length, String type) throws IOException(Code)(Java Doc) abstract public void writeListEnd() throws IOException(Code)(Java Doc) abstract public void writeLong(long value) throws IOException(Code)(Java Doc) abstract public void writeMapBegin(String type) throws IOException(Code)(Java Doc) abstract public void writeMapEnd() throws IOException(Code)(Java Doc) abstract public void writeMethod(String method) throws IOException(Code)(Java Doc) abstract public void writeNull() throws IOException(Code)(Java Doc) abstract public void writeObject(Object object) throws IOException(Code)(Java Doc) public int writeObjectBegin(String type) throws IOException(Code)(Java Doc) public void writeObjectEnd() throws IOException(Code)(Java Doc) abstract public void writeRef(int value) throws IOException(Code)(Java Doc) abstract public void writeRemote(String type, String url) throws IOException(Code)(Java Doc) abstract public void writeString(String value) throws IOException(Code)(Java Doc) abstract public void writeString(char[] buffer, int offset, int length) throws IOException(Code)(Java Doc) abstract public void writeUTCDate(long time) throws IOException(Code)(Java Doc)
|
|
|