Package com.prineside.tdi2.managers
Class NetworkManager.KryoForState
java.lang.Object
com.esotericsoftware.kryo.Kryo
com.prineside.tdi2.managers.NetworkManager.KryoForState
- Enclosing class:
- NetworkManager
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetRegistration
(Class type) If the class is not registered andKryo.setRegistrationRequired(boolean)
is false, it is automatically registered using thedefault serializer
.boolean
hasRegistration
(Class type) register
(Registration registration) Stores the specified registration.register
(Class type, Serializer serializer) Registers the class using the lowest, next available integer ID and the specified serializer.Methods inherited from class com.esotericsoftware.kryo.Kryo
addDefaultSerializer, addDefaultSerializer, addDefaultSerializer, copy, copy, copyShallow, copyShallow, getClassLoader, getClassResolver, getContext, getDefaultSerializer, getDepth, getGenerics, getGraphContext, getInstantiatorStrategy, getNextRegistrationId, getOriginalToCopyMap, getReferenceResolver, getReferences, getRegistration, getSerializer, getWarnUnregisteredClasses, isClosure, isFinal, isProxy, isRegistrationRequired, newInstance, readClass, readClassAndObject, readObject, readObject, readObjectOrNull, readObjectOrNull, reference, register, register, register, reset, setAutoReset, setClassLoader, setCopyReferences, setDefaultSerializer, setDefaultSerializer, setInstantiatorStrategy, setMaxDepth, setOptimizedGenerics, setReferenceResolver, setReferences, setRegistrationRequired, setWarnUnregisteredClasses, writeClass, writeClassAndObject, writeObject, writeObject, writeObjectOrNull, writeObjectOrNull
-
Constructor Details
-
KryoForState
public KryoForState()
-
-
Method Details
-
register
Description copied from class:com.esotericsoftware.kryo.Kryo
Stores the specified registration. If the ID is already in use by the same type, the old entry is overwritten. Registering a primitive also affects the corresponding primitive wrapper.IDs must be the same at deserialization as they were for serialization.
Registration can be suclassed to efficiently store per type information, accessible in serializers via
Kryo.getRegistration(Class)
. -
register
Description copied from class:com.esotericsoftware.kryo.Kryo
Registers the class using the lowest, next available integer ID and the specified serializer. If the class is already registered, the existing entry is updated with the new serializer. Registering a primitive also affects the corresponding primitive wrapper.Because the ID assigned is affected by the IDs registered before it, the order classes are registered is important when using this method. The order must be the same at deserialization as it was for serialization.
-
hasRegistration
-
getRegistration
Description copied from class:com.esotericsoftware.kryo.Kryo
If the class is not registered andKryo.setRegistrationRequired(boolean)
is false, it is automatically registered using thedefault serializer
.- Overrides:
getRegistration
in classKryo
- See Also:
-