| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected <T> T | deserialize(String
the string to deserialze serialized, Class<T> the class into which to deserialize the string type)Implements abstract com. Deserializes an object from a string for storage. |
| protected <T> List | deserializeList(String
the string to deserialze serialized, Class<T> the class into which to deserialize the string type)Implements abstract com. Deserializes a list of objects from a string for storage. |
| protected String | serialize(Object
the object to serialize object)Implements abstract com. Serializes an object to a string for storage. |
| gson | back to summary |
|---|---|
| private final Gson gson | |
| StorageHandlerImpl | back to summary |
|---|---|
| public StorageHandlerImpl(Class<?> saveClass) | |
| deserialize | back to summary |
|---|---|
| protected <T> T deserialize(String serialized, Class<T> type) Implements abstract com. Doc from com. Deserializes an object from a string for storage. Subclasses may use any way to deserialize the object.
This should be the inverse operation of Therefore the following must hold true for any x of type X: Objects.equals(x, deserialize(serialize(x), X.class) | |
| deserializeList | back to summary |
|---|---|
| protected <T> List Implements abstract com. Doc from com. Deserializes a list of objects from a string for storage. Subclasses may use any way to deserialize the list.
This should be the inverse operation of Therefore the following must hold true for any x of type List<X>: Objects.equals(x, deserializeList(serialize(x), X.class) | |
| serialize | back to summary |
|---|---|
| protected String serialize(Object object) Implements abstract com. Doc from com. Serializes an object to a string for storage. Subclasses may use any way to serialize the object.
This should be the inverse operation of Therefore the following must hold true for any x of type X: Objects.equals(x, deserialize(serialize(x), X.class) | |