Package org.jboss.marshalling.cloner
Class SerializingCloner.StepObjectOutput
java.lang.Object
java.io.OutputStream
org.jboss.marshalling.SimpleByteOutput
org.jboss.marshalling.ByteOutputStream
org.jboss.marshalling.SimpleDataOutput
org.jboss.marshalling.AbstractObjectOutput
org.jboss.marshalling.cloner.SerializingCloner.StepObjectOutput
- All Implemented Interfaces:
Closeable
,DataOutput
,Flushable
,ObjectOutput
,AutoCloseable
,ByteOutput
,Marshaller
- Enclosing class:
- SerializingCloner
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ByteArrayOutputStream
private final Queue<SerializingCloner.Step>
Fields inherited from class org.jboss.marshalling.SimpleDataOutput
buffer, bufferSize
Fields inherited from class org.jboss.marshalling.ByteOutputStream
byteOutput
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Discard the class cache.void
Discard the instance cache.(package private) void
doFinish()
protected void
doWriteObject
(Object obj, boolean unshared) Implementation of the actual object-writing method.void
finish()
Finish writing to a stream.void
flush()
void
start
(ByteOutput byteOutput) Begin writing to a stream.Methods inherited from class org.jboss.marshalling.AbstractObjectOutput
writeObject, writeObjectUnshared
Methods inherited from class org.jboss.marshalling.SimpleDataOutput
close, shallowFlush, write, write, write, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTF
Methods inherited from class java.io.OutputStream
nullOutputStream
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.jboss.marshalling.ByteOutput
write, write, write
Methods inherited from interface java.io.DataOutput
writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTF
Methods inherited from interface org.jboss.marshalling.Marshaller
writeObjectUnshared
Methods inherited from interface java.io.ObjectOutput
close, write, write, write, writeObject
-
Field Details
-
steps
-
byteArrayOutputStream
-
-
Constructor Details
-
StepObjectOutput
StepObjectOutput(Queue<SerializingCloner.Step> steps) throws IOException - Throws:
IOException
-
-
Method Details
-
doWriteObject
Description copied from class:AbstractObjectOutput
Implementation of the actual object-writing method.- Specified by:
doWriteObject
in classAbstractObjectOutput
- Parameters:
obj
- the object to writeunshared
-true
if the instance is unshared,false
if it is shared- Throws:
IOException
- if an I/O error occurs
-
clearInstanceCache
Description copied from interface:Marshaller
Discard the instance cache. May also discard the class cache in implementations that do not support separated class and instance caches.- Specified by:
clearInstanceCache
in interfaceMarshaller
- Throws:
IOException
- if an error occurs
-
clearClassCache
Description copied from interface:Marshaller
Discard the class cache. Implicitly also discards the instance cache.- Specified by:
clearClassCache
in interfaceMarshaller
- Throws:
IOException
- if an error occurs
-
start
Description copied from class:SimpleDataOutput
Begin writing to a stream.- Specified by:
start
in interfaceMarshaller
- Overrides:
start
in classSimpleDataOutput
- Parameters:
byteOutput
- the new stream- Throws:
IOException
- if an error occurs
-
finish
Description copied from class:SimpleDataOutput
Finish writing to a stream. The stream is released. No further writing may be done until theSimpleDataOutput.start(ByteOutput)
method is again invoked.- Specified by:
finish
in interfaceMarshaller
- Overrides:
finish
in classSimpleDataOutput
- Throws:
IOException
- if an error occurs
-
doFinish
- Throws:
IOException
-
flush
Description copied from class:SimpleDataOutput
- Specified by:
flush
in interfaceFlushable
- Specified by:
flush
in interfaceObjectOutput
- Overrides:
flush
in classSimpleDataOutput
- Throws:
IOException
-