public class Utils extends Object
| Constructor and Description |
|---|
Utils() |
| Modifier and Type | Method and Description |
|---|---|
static <T> T |
getUnmarshalledObject(Path source,
Path schema,
Class<T> bindingClass)
Builds an XML binding from the XML source file specified.
|
static Unmarshaller |
getXMLUnmarshaller(Path schemaPath,
Class... classes)
Returns an XML unmarshaller for the defined Java classes.
|
public static Unmarshaller getXMLUnmarshaller(Path schemaPath, Class... classes) throws ApplicationServerConfigurationException
schemaPath - file path of the XML schema file against which the source XML is to be
validatedclasses - the list of classes to be recognized by the JAXBContextApplicationServerConfigurationException - if an error occurs when creating the XML unmarshallerpublic static <T> T getUnmarshalledObject(Path source, Path schema, Class<T> bindingClass) throws ApplicationServerConfigurationException
T - the type of the class to be boundsource - the XML source file path representationschema - an optional file path representation of an XML schema file against which the source XML
is to be validatedbindingClass - the class to be recognized by the JAXBContextApplicationServerConfigurationException - if an error occurred when creating the unmarshaller or
unmarshalling the XML sourceCopyright © 2016 WSO2. All rights reserved.