Class JAXBUtil
java.lang.Object
org.keycloak.saml.processing.core.util.JAXBUtil
Utility to obtain JAXB2 marshaller/unmarshaller etc
- Since:
- May 26, 2009
- Author:
- Anil.Saldhana@redhat.com
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic jakarta.xml.bind.JAXBContext
getJAXBContext
(Class<?> clazz) static jakarta.xml.bind.JAXBContext
getJAXBContext
(String path) static jakarta.xml.bind.JAXBContext
getJAXBContext
(String... paths) static jakarta.xml.bind.Marshaller
getMarshaller
(String pkgName) Get the JAXB Marshallerstatic jakarta.xml.bind.Unmarshaller
getUnmarshaller
(String pkgName) Get the JAXB Unmarshallerstatic jakarta.xml.bind.Unmarshaller
getUnmarshaller
(String... pkgNames) Get the JAXB Unmarshaller for a selected set of package namesstatic jakarta.xml.bind.Marshaller
getValidatingMarshaller
(String pkgName, String schemaLocation) Get the JAXB Marshallerstatic jakarta.xml.bind.Unmarshaller
getValidatingUnmarshaller
(String[] pkgNames, String[] schemaLocations) static jakarta.xml.bind.Unmarshaller
getValidatingUnmarshaller
(String pkgName, String schemaLocation) Get the JAXB Unmarshaller
-
Field Details
-
W3C_XML_SCHEMA_NS_URI
- See Also:
-
-
Constructor Details
-
JAXBUtil
public JAXBUtil()
-
-
Method Details
-
getValidatingMarshaller
public static jakarta.xml.bind.Marshaller getValidatingMarshaller(String pkgName, String schemaLocation) throws jakarta.xml.bind.JAXBException, SAXException Get the JAXB Marshaller- Parameters:
pkgName
- The package name for the jaxb contextschemaLocation
- location of the schema to validate against- Returns:
- Marshaller
- Throws:
jakarta.xml.bind.JAXBException
SAXException
-
getMarshaller
public static jakarta.xml.bind.Marshaller getMarshaller(String pkgName) throws jakarta.xml.bind.JAXBException Get the JAXB Marshaller- Parameters:
pkgName
- The package name for the jaxb context- Returns:
- Marshaller
- Throws:
jakarta.xml.bind.JAXBException
-
getUnmarshaller
public static jakarta.xml.bind.Unmarshaller getUnmarshaller(String pkgName) throws jakarta.xml.bind.JAXBException Get the JAXB Unmarshaller- Parameters:
pkgName
- The package name for the jaxb context- Returns:
- unmarshaller
- Throws:
jakarta.xml.bind.JAXBException
-
getUnmarshaller
public static jakarta.xml.bind.Unmarshaller getUnmarshaller(String... pkgNames) throws jakarta.xml.bind.JAXBException Get the JAXB Unmarshaller for a selected set of package names- Parameters:
pkgNames
-- Returns:
- Throws:
jakarta.xml.bind.JAXBException
-
getValidatingUnmarshaller
public static jakarta.xml.bind.Unmarshaller getValidatingUnmarshaller(String pkgName, String schemaLocation) throws jakarta.xml.bind.JAXBException, SAXException Get the JAXB Unmarshaller- Parameters:
pkgName
- The package name for the jaxb contextschemaLocation
- location of the schema to validate against- Returns:
- unmarshaller
- Throws:
jakarta.xml.bind.JAXBException
SAXException
-
getValidatingUnmarshaller
public static jakarta.xml.bind.Unmarshaller getValidatingUnmarshaller(String[] pkgNames, String[] schemaLocations) throws jakarta.xml.bind.JAXBException, SAXException, IOException - Throws:
jakarta.xml.bind.JAXBException
SAXException
IOException
-
getJAXBContext
public static jakarta.xml.bind.JAXBContext getJAXBContext(String path) throws jakarta.xml.bind.JAXBException - Throws:
jakarta.xml.bind.JAXBException
-
getJAXBContext
public static jakarta.xml.bind.JAXBContext getJAXBContext(String... paths) throws jakarta.xml.bind.JAXBException - Throws:
jakarta.xml.bind.JAXBException
-
getJAXBContext
public static jakarta.xml.bind.JAXBContext getJAXBContext(Class<?> clazz) throws jakarta.xml.bind.JAXBException - Throws:
jakarta.xml.bind.JAXBException
-