Package de.hsh.graja.transform
Class TransformBetweenProformaResponseAndGraja
java.lang.Object
de.hsh.graja.transform.TransformBetweenProformaResponseAndGraja
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic GrajaResultTOstatic GrajaResultTOstatic ProformaResponseResultTOconvertToProformaResponse(GrajaResultTO gsr, LocalDateTime timestamp, ResultSpecTO resultSpec) static ResponseTypecreateProformaErrorResponse(LocalDateTime timestamp, String msg) static ProformaResponseResultTOcreateProformaResponseResultFromProformaResponse(ResponseType response, String format) static byte[]createSerializedProformaErrorResponse(LocalDateTime timestamp, String msg, String format) static ResponseTypedeserializeResponse(byte[] content) static byte[]serializeResponse(ResponseType response, String format)
-
Constructor Details
-
TransformBetweenProformaResponseAndGraja
public TransformBetweenProformaResponseAndGraja()
-
-
Method Details
-
convertToProformaResponse
public static ProformaResponseResultTO convertToProformaResponse(GrajaResultTO gsr, LocalDateTime timestamp, ResultSpecTO resultSpec) throws javax.xml.bind.JAXBException, IOException - Throws:
javax.xml.bind.JAXBExceptionIOException
-
createProformaResponseResultFromProformaResponse
public static ProformaResponseResultTO createProformaResponseResultFromProformaResponse(ResponseType response, String format) throws javax.xml.bind.JAXBException, IOException - Throws:
javax.xml.bind.JAXBExceptionIOException
-
convertToGrajaResult
public static GrajaResultTO convertToGrajaResult(ProformaResponseResultTO in) throws javax.xml.bind.JAXBException, IOException - Throws:
javax.xml.bind.JAXBExceptionIOException
-
convertToGrajaResult
public static GrajaResultTO convertToGrajaResult(ResponseType in) throws javax.xml.bind.JAXBException, IOException - Throws:
javax.xml.bind.JAXBExceptionIOException
-
serializeResponse
public static byte[] serializeResponse(ResponseType response, String format) throws javax.xml.bind.JAXBException, IOException - Parameters:
response-format- xml or zip (as result-spec/format in the ProFormA submission format)- Returns:
- Throws:
javax.xml.bind.JAXBExceptionIOException
-
deserializeResponse
public static ResponseType deserializeResponse(byte[] content) throws javax.xml.bind.JAXBException, IOException - Throws:
javax.xml.bind.JAXBExceptionIOException
-
createProformaErrorResponse
-
createSerializedProformaErrorResponse
public static byte[] createSerializedProformaErrorResponse(LocalDateTime timestamp, String msg, String format) throws javax.xml.bind.JAXBException, IOException - Throws:
javax.xml.bind.JAXBExceptionIOException
-