public class TypeMarshaller extends Object
| Constructor and Description |
|---|
TypeMarshaller() |
| Modifier and Type | Method and Description |
|---|---|
static File |
marshalTypeToFile(Object typeObject,
String filenamePath) |
static void |
marshalTypeToOutputStream(Object typeObject,
OutputStream os) |
static void |
marshalTypeToOutputStream(Object typeObject,
OutputStream os,
String styleSheet)
Marshalls the typeObject to the provided outputStream.
|
static <T> T |
unmarshalTypeFromFile(Class<T> domainClass,
File file)
Unmarshalls the contents of file parameter to the specified domainClass
|
static <T> T |
unmarshalTypeFromFile(Class<T> domainClass,
String filenamePath)
Unmarshalls the contents of the filenamePath into the specified domainClass
|
static <T> T |
unmarshalTypeFromStream(Class<T> domainClass,
InputStream inputStream)
Unmarshalls the inputStream to the specified domainClass
and unequivocally closes the passed in InputStream
|
public static File marshalTypeToFile(Object typeObject, String filenamePath) throws org.jibx.runtime.JiBXException, FileNotFoundException, IOException
org.jibx.runtime.JiBXExceptionFileNotFoundExceptionIOExceptionpublic static void marshalTypeToOutputStream(Object typeObject, OutputStream os) throws org.jibx.runtime.JiBXException, IOException
org.jibx.runtime.JiBXExceptionIOExceptionpublic static void marshalTypeToOutputStream(Object typeObject, OutputStream os, String styleSheet) throws org.jibx.runtime.JiBXException, IOException
typeObject - os - styleSheet - org.jibx.runtime.JiBXExceptionIOExceptionpublic static <T> T unmarshalTypeFromFile(Class<T> domainClass, String filenamePath) throws IOException, InstantiationException, IllegalAccessException, org.jibx.runtime.JiBXException
T - domainClass - filenamePath - IOExceptionInstantiationExceptionIllegalAccessExceptionorg.jibx.runtime.JiBXExceptionpublic static <T> T unmarshalTypeFromFile(Class<T> domainClass, File file) throws IOException, InstantiationException, IllegalAccessException, org.jibx.runtime.JiBXException
T - domainClass - file - IOExceptionInstantiationExceptionIllegalAccessExceptionorg.jibx.runtime.JiBXExceptionpublic static <T> T unmarshalTypeFromStream(Class<T> domainClass, InputStream inputStream) throws IOException, InstantiationException, IllegalAccessException, org.jibx.runtime.JiBXException
T - domainClass - inputStream - IOExceptionInstantiationExceptionIllegalAccessExceptionorg.jibx.runtime.JiBXExceptionCopyright © 2014. All Rights Reserved.