Package org.rostore.mapper
Class BinaryMapper
java.lang.Object
org.rostore.mapper.BinaryMapper
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> Tdeserialize(MapperProperties mediaProperties, Type type, InputStream inputStream) static <T> Tdeserialize(MapperProperties mapperProperties, Type type, InputStream inputStream, int limit) static intreadLength(InputStream data) static StringreadString(InputStream data) static <T> voidserialize(MapperProperties mediaProperties, T object, OutputStream outputStream) static <T> voidserialize(MapperProperties mediaProperties, T object, Type type, OutputStream outputStream) static voidwrite(OutputStream data, String value) static voidwriteLength(OutputStream data, int dataLength)
-
Constructor Details
-
BinaryMapper
public BinaryMapper()
-
-
Method Details
-
write
- Throws:
IOException
-
writeLength
- Throws:
IOException
-
readString
- Throws:
IOException
-
readLength
- Throws:
IOException
-
serialize
public static <T> void serialize(MapperProperties mediaProperties, T object, OutputStream outputStream) -
serialize
public static <T> void serialize(MapperProperties mediaProperties, T object, Type type, OutputStream outputStream) -
deserialize
public static <T> T deserialize(MapperProperties mediaProperties, Type type, InputStream inputStream) -
deserialize
public static <T> T deserialize(MapperProperties mapperProperties, Type type, InputStream inputStream, int limit) - Type Parameters:
T-- Parameters:
mapperProperties-type-inputStream-limit- it will stop after deserializing that many fields- Returns:
-