Class KryoShimServiceLoader
- java.lang.Object
- 
- org.apache.tinkerpop.gremlin.structure.io.gryo.kryoshim.KryoShimServiceLoader
 
- 
 public class KryoShimServiceLoader extends Object Loads the highest-priority or user-selectedKryoShimService.
- 
- 
Field SummaryFields Modifier and Type Field Description static StringKRYO_SHIM_SERVICESet this system property to the fully-qualified name of aKryoShimServicepackage-and-classname to force it into service.
 - 
Constructor SummaryConstructors Constructor Description KryoShimServiceLoader()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static voidapplyConfiguration(org.apache.commons.configuration2.Configuration configuration)static voidclose()static <T> TreadClassAndObject(InputStream inputStream)A loose abstraction ofKryo.readClassAndObject(org.apache.tinkerpop.shaded.kryo.io.Input), where theinputparameter issource.static byte[]writeClassAndObjectToBytes(Object object)A loose abstraction ofKryo.writeClassAndObject(org.apache.tinkerpop.shaded.kryo.io.Output, java.lang.Object), where theoutputparameter is an internally-createdByteArrayOutputStream.
 
- 
- 
- 
Field Detail- 
KRYO_SHIM_SERVICEpublic static final String KRYO_SHIM_SERVICE Set this system property to the fully-qualified name of aKryoShimServicepackage-and-classname to force it into service. Setting this property causes the priority-selection mechanism (KryoShimService.getPriority()) to be ignored.- See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
applyConfigurationpublic static void applyConfiguration(org.apache.commons.configuration2.Configuration configuration) 
 - 
closepublic static void close() 
 - 
writeClassAndObjectToBytespublic static byte[] writeClassAndObjectToBytes(Object object) A loose abstraction ofKryo.writeClassAndObject(org.apache.tinkerpop.shaded.kryo.io.Output, java.lang.Object), where theoutputparameter is an internally-createdByteArrayOutputStream. Returns the byte array underlying that stream.- Parameters:
- object- an object for which the instance and class are serialized
- Returns:
- the serialized form
 
 - 
readClassAndObjectpublic static <T> T readClassAndObject(InputStream inputStream) A loose abstraction ofKryo.readClassAndObject(org.apache.tinkerpop.shaded.kryo.io.Input), where theinputparameter issource. Returns the deserialized object.- Type Parameters:
- T- the type to which the deserialized object is cast as it is returned
- Parameters:
- inputStream- an input stream containing data for a serialized object class and instance
- Returns:
- the deserialized object
 
 
- 
 
-