Package org.nustaq.serialization
Class FSTObjectInputNoShared
java.lang.Object
org.nustaq.serialization.FSTObjectInput
org.nustaq.serialization.FSTObjectInputNoShared
- All Implemented Interfaces:
DataInput
,ObjectInput
,AutoCloseable
Subclass optimized for "unshared mode". Cycles and Objects referenced more than once will not be detected.
Additionally JDK compatibility is not supported (read/writeObject and stuff). Use case is highperformance
serialization of plain cycle free data (e.g. messaging). Can perform significantly faster (20-40%).
-
Nested Class Summary
Nested classes/interfaces inherited from class org.nustaq.serialization.FSTObjectInput
FSTObjectInput.CallbackEntry, FSTObjectInput.ConditionalCallback, FSTObjectInput.MyObjectStream
-
Field Summary
Fields inherited from class org.nustaq.serialization.FSTObjectInput
callbacks, clInfoRegistry, closed, codec, conditionalCallback, conf, curDepth, debugStack, emptyStream, fakeWrapper, ignoreAnnotations, infoCache, isCrossPlatform, objects, readExternalReadAHead, REGISTER_ENUMS_READ, versionConflictListener
-
Constructor Summary
ConstructorDescriptionCreates a FSTObjectInput that uses the specified underlying InputStream.Creates a FSTObjectInput that uses the specified underlying InputStream. -
Method Summary
Modifier and TypeMethodDescriptionprotected Object
instantiateAndReadNoSer
(Class c, FSTClazzInfo clzSerInfo, FSTClazzInfo.FSTFieldInfo referencee, int readPos) void
registerObject
(Object o, int streamPosition, FSTClazzInfo info, FSTClazzInfo.FSTFieldInfo referencee) void
void
resetForReuseCopyArray
(byte[] bytes, int off, int len) Methods inherited from class org.nustaq.serialization.FSTObjectInput
available, close, defaultReadObject, getClassForName, getClazzInfo, getCodec, getConditionalCallback, getConf, getObjectInputStream, getReadExternalReadAHead, getVersionConflictListener, handleReadRessolve, initRegistries, instantiateAndReadWithSer, instantiateArray, instantiateBigInt, instantiateEnum, instantiateHandle, instantiateSpecialTag, isClosed, oldVersionRead, processValidation, pushBack, read, read, read, readArray, readArrayNoHeader, readBoolean, readByte, readChar, readClass, readCompatibleObjectFields, readDouble, readFieldsMapBased, readFInt, readFloat, readFully, readFully, readInt, readLine, readLong, readObject, readObject, readObjectCompatible, readObjectCompatibleRecursive, readObjectFields, readObjectInternal, readObjectWithHeader, readShort, readStringAsc, readStringUTF, readUnsignedByte, readUnsignedShort, readUTF, reset, resetAndClearRefs, resetForReuseUseArray, resetForReuseUseArray, setCodec, setConditionalCallback, setReadExternalReadAHead, setVersionConflictListener, skip, skipBytes, skipConditional
-
Constructor Details
-
FSTObjectInputNoShared
- Throws:
IOException
-
FSTObjectInputNoShared
-
FSTObjectInputNoShared
Creates a FSTObjectInput that uses the specified underlying InputStream.- Parameters:
in
- the specified input stream- Throws:
IOException
-
FSTObjectInputNoShared
Creates a FSTObjectInput that uses the specified underlying InputStream. Don't create a FSTConfiguration with each stream, just create one global static configuration and reuseit. FSTConfiguration is threadsafe.- Parameters:
in
- the specified input streamconf
-
-
-
Method Details
-
registerObject
public void registerObject(Object o, int streamPosition, FSTClazzInfo info, FSTClazzInfo.FSTFieldInfo referencee) - Overrides:
registerObject
in classFSTObjectInput
-
resetForReuse
- Overrides:
resetForReuse
in classFSTObjectInput
- Throws:
IOException
-
resetForReuseCopyArray
- Overrides:
resetForReuseCopyArray
in classFSTObjectInput
- Throws:
IOException
-
instantiateAndReadNoSer
protected Object instantiateAndReadNoSer(Class c, FSTClazzInfo clzSerInfo, FSTClazzInfo.FSTFieldInfo referencee, int readPos) throws Exception - Overrides:
instantiateAndReadNoSer
in classFSTObjectInput
- Throws:
Exception
-