Package de.hsh.graja.transform
Class TransformBetweenProformaResponseAndGraja
- java.lang.Object
-
- de.hsh.graja.transform.TransformBetweenProformaResponseAndGraja
-
public class TransformBetweenProformaResponseAndGraja extends Object
-
-
Constructor Summary
Constructors Constructor Description TransformBetweenProformaResponseAndGraja()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static GrajaSingleResultTO
convertToGrajaResult(ProformaResponseResultTO in)
static ProformaResponseResultTO
convertToProformaResponse(GrajaResultTO in, LocalDateTime timestamp, ResultSpecTO resultSpec)
static ResponseType
createProformaErrorResponse(LocalDateTime timestamp, String msg)
static ProformaResponseResultTO
createProformaResponseResultFromProformaResponse(ResponseType response, String format)
static byte[]
createSerializedProformaErrorResponse(LocalDateTime timestamp, String msg, String format)
static ResponseType
deserializeResponse(byte[] content)
static byte[]
serializeResponse(ResponseType response, String format)
-
-
-
Method Detail
-
convertToProformaResponse
public static ProformaResponseResultTO convertToProformaResponse(GrajaResultTO in, LocalDateTime timestamp, ResultSpecTO resultSpec) throws javax.xml.bind.JAXBException, IOException
- Throws:
javax.xml.bind.JAXBException
IOException
-
createProformaResponseResultFromProformaResponse
public static ProformaResponseResultTO createProformaResponseResultFromProformaResponse(ResponseType response, String format) throws javax.xml.bind.JAXBException, IOException
- Throws:
javax.xml.bind.JAXBException
IOException
-
convertToGrajaResult
public static GrajaSingleResultTO convertToGrajaResult(ProformaResponseResultTO in) throws javax.xml.bind.JAXBException, IOException
- Throws:
javax.xml.bind.JAXBException
IOException
-
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.JAXBException
IOException
-
deserializeResponse
public static ResponseType deserializeResponse(byte[] content) throws javax.xml.bind.JAXBException, IOException
- Throws:
javax.xml.bind.JAXBException
IOException
-
createProformaErrorResponse
public static ResponseType createProformaErrorResponse(LocalDateTime timestamp, String msg)
-
createSerializedProformaErrorResponse
public static byte[] createSerializedProformaErrorResponse(LocalDateTime timestamp, String msg, String format) throws javax.xml.bind.JAXBException, IOException
- Throws:
javax.xml.bind.JAXBException
IOException
-
-