|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectat.spardat.xma.serializer.BinarySerializer
Serializer implementation that uses the Java-Serialization mechanism
| Constructor Summary | |
BinarySerializer(boolean isAtServer,
int bufferSize)
Constructor |
|
| Method Summary | |
void |
addHeader()
Indicates that the result-ByteArray should include a header. |
ByteArray |
getResult()
Returns the array of bytes that is the result of the serialization process. |
boolean |
isAtServer()
Returns whether this is produced at the server or at the client. |
void |
writeBoolean(java.lang.String label,
boolean b)
Writes a boolean |
void |
writeByte(java.lang.String label,
int b)
Write a byte |
void |
writeInt(java.lang.String label,
int i)
Writes an int |
void |
writeLong(java.lang.String label,
long l)
Writes a long |
void |
writeObject(java.lang.String label,
java.lang.Object obj)
Writes an Object. |
void |
writeSerializedBytes(java.lang.String label,
byte[] bytes)
Write a sequence of bytes that is the output of the same kind of Serializer that is active now, i.e., providing this XmaOutput. |
void |
writeShort(java.lang.String label,
int s)
Writes a short |
void |
writeString(java.lang.String label,
java.lang.String s)
Outputs a String |
void |
writeStringN(java.lang.String label,
java.lang.String s)
Same as writeString, except that s may be null; |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public BinarySerializer(boolean isAtServer,
int bufferSize)
isAtServer - is this serializer running at the server side?bufferSize - initial buffer size| Method Detail |
public void addHeader()
Serializer
addHeader in interface SerializerSerializer.addHeader()public boolean isAtServer()
Serializer
isAtServer in interface SerializerSerializer.isAtServer()public ByteArray getResult()
Serializer
getResult in interface SerializerSerializer.getResult()
public void writeString(java.lang.String label,
java.lang.String s)
throws java.io.IOException
XmaOutput
writeString in interface XmaOutputlabel - short string that describes what the second parameter means;
this string has only descriptive purpose.s - the String; must not be null
java.io.IOException
public void writeStringN(java.lang.String label,
java.lang.String s)
throws java.io.IOException
XmaOutput
writeStringN in interface XmaOutputjava.io.IOExceptionXmaOutput.writeStringN(java.lang.String, java.lang.String)
public void writeInt(java.lang.String label,
int i)
throws java.io.IOException
XmaOutput
writeInt in interface XmaOutputlabel - short string that describes what the second parameter means;
this string has only descriptive purpose.i - the int
java.io.IOException
public void writeLong(java.lang.String label,
long l)
throws java.io.IOException
XmaOutput
writeLong in interface XmaOutputlabel - short string that describes what the second parameter means;
this string has only descriptive purpose.l - the long
java.io.IOException
public void writeShort(java.lang.String label,
int s)
throws java.io.IOException
XmaOutput
writeShort in interface XmaOutputlabel - short string that describes what the second parameter means;
this string has only descriptive purpose.s - the short
java.io.IOException
public void writeBoolean(java.lang.String label,
boolean b)
throws java.io.IOException
XmaOutput
writeBoolean in interface XmaOutputlabel - short string that describes what the second parameter means;
this string has only descriptive purpose.b - the boolean
java.io.IOException
public void writeByte(java.lang.String label,
int b)
throws java.io.IOException
XmaOutput
writeByte in interface XmaOutputlabel - short string that describes what the second parameter means;
this string has only descriptive purpose.b - the byte
java.io.IOException
public void writeSerializedBytes(java.lang.String label,
byte[] bytes)
throws java.io.IOException
XmaOutput
writeSerializedBytes in interface XmaOutputbytes - sequence of bytes; must not be null
java.io.IOExceptionXmaOutput.writeSerializedBytes(String, byte[])
public void writeObject(java.lang.String label,
java.lang.Object obj)
throws java.io.IOException
XmaOutput
writeObject in interface XmaOutputobj - the object to serialize; must not be null
java.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||