public final class PersisterHelpers extends Object
| Constructor and Description |
|---|
PersisterHelpers() |
| Modifier and Type | Method and Description |
|---|---|
static org.simpleframework.xml.core.Persister |
createPersister(ResourceLookup resourceLookup,
org.simpleframework.xml.strategy.Strategy strategy)
Create a persister with the given
ResourceLookup key. |
static ResourceLookup |
getResourceLookup(Map<Object,Object> session)
Acquire
ResourceLookup from a serialization/ deserialization session. |
static <T> T |
read(ResourceLookup resourceLookup,
String resource,
Class<T> clazz,
boolean required)
Read and deserialize an XML resource of class
clazz. |
public static ResourceLookup getResourceLookup(Map<Object,Object> session)
ResourceLookup from a serialization/ deserialization session.public static org.simpleframework.xml.core.Persister createPersister(ResourceLookup resourceLookup, org.simpleframework.xml.strategy.Strategy strategy)
ResourceLookup key.public static <T> T read(ResourceLookup resourceLookup, String resource, Class<T> clazz, boolean required) throws IOException
clazz.T - Class to be deserialized.required - If true, missing resources will throw an IOException.null if required
is false.IOException