diff options
author | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2014-05-07 09:27:33 +0200 |
---|---|---|
committer | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2014-05-07 09:27:33 +0200 |
commit | 6a588fa992b35eb3e31a3f183cbb7639288d2a57 (patch) | |
tree | 6cf8878350c27b27a7c3ed5ec9e08d5f8a38f910 /pdf-as-common/src/main/java/at/gv | |
parent | e9410c03edfcfee9b6aa6dc5a27d6532292d72d8 (diff) | |
download | pdf-as-4-6a588fa992b35eb3e31a3f183cbb7639288d2a57.tar.gz pdf-as-4-6a588fa992b35eb3e31a3f183cbb7639288d2a57.tar.bz2 pdf-as-4-6a588fa992b35eb3e31a3f183cbb7639288d2a57.zip |
XML Elements renaming for SOAP service
Diffstat (limited to 'pdf-as-common/src/main/java/at/gv')
6 files changed, 75 insertions, 10 deletions
diff --git a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASBulkSignRequest.java b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASBulkSignRequest.java new file mode 100644 index 00000000..01fe8db3 --- /dev/null +++ b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASBulkSignRequest.java @@ -0,0 +1,27 @@ +package at.gv.egiz.pdfas.api.ws; + +import java.io.Serializable; +import java.util.List; + +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + +@XmlType(name="BulkSignRequest") +public class PDFASBulkSignRequest implements Serializable { + + /** + * + */ + private static final long serialVersionUID = 2335377335418211956L; + + List<PDFASSignRequest> signRequests; + + @XmlElement(required = true, nillable = false, name="signRequests") + public List<PDFASSignRequest> getSignRequests() { + return signRequests; + } + + public void setSignRequests(List<PDFASSignRequest> signRequests) { + this.signRequests = signRequests; + } +} diff --git a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASBulkSignResponse.java b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASBulkSignResponse.java new file mode 100644 index 00000000..c89a1498 --- /dev/null +++ b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASBulkSignResponse.java @@ -0,0 +1,27 @@ +package at.gv.egiz.pdfas.api.ws; + +import java.io.Serializable; +import java.util.List; + +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; + +@XmlType(name="BulkSignResponse") +public class PDFASBulkSignResponse implements Serializable { + + /** + * + */ + private static final long serialVersionUID = 4218977934947700835L; + + List<PDFASSignResponse> signResponses; + + @XmlElement(required = true, nillable = false, name="signResponses") + public List<PDFASSignResponse> getSignResponses() { + return signResponses; + } + + public void setSignResponses(List<PDFASSignResponse> signResponses) { + this.signResponses = signResponses; + } +} diff --git a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignParameters.java b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignParameters.java index 070ca473..4f626e17 100644 --- a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignParameters.java +++ b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignParameters.java @@ -3,7 +3,9 @@ package at.gv.egiz.pdfas.api.ws; import java.io.Serializable; import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; +@XmlType(name="SignParameters") public class PDFASSignParameters implements Serializable { /** @@ -11,6 +13,7 @@ public class PDFASSignParameters implements Serializable { */ private static final long serialVersionUID = -2375108993871456465L; + @XmlType(name="Connector") public enum Connector { JKS, MOA @@ -25,7 +28,7 @@ public class PDFASSignParameters implements Serializable { String profile; - @XmlElement(required = true, nillable = false) + @XmlElement(required = true, nillable = false, name="connector") public Connector getConnector() { return connector; } @@ -34,7 +37,7 @@ public class PDFASSignParameters implements Serializable { this.connector = connector; } - @XmlElement(required = false, nillable = true) + @XmlElement(required = false, nillable = true, name="position") public String getPosition() { return position; } @@ -42,7 +45,7 @@ public class PDFASSignParameters implements Serializable { this.position = position; } - @XmlElement(required = false, nillable = true) + @XmlElement(required = false, nillable = true, name="profile") public String getProfile() { return profile; } diff --git a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignRequest.java b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignRequest.java index c875171d..e0d87004 100644 --- a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignRequest.java +++ b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignRequest.java @@ -3,7 +3,9 @@ package at.gv.egiz.pdfas.api.ws; import java.io.Serializable; import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; +@XmlType(name="SignRequest") public class PDFASSignRequest implements Serializable { /** @@ -15,7 +17,7 @@ public class PDFASSignRequest implements Serializable { byte[] inputData; PDFASSignParameters parameters; - @XmlElement(required = true, nillable = false) + @XmlElement(required = true, nillable = false, name="requestID") public String getRequestID() { return requestID; } @@ -24,7 +26,7 @@ public class PDFASSignRequest implements Serializable { this.requestID = requestID; } - @XmlElement(required = true, nillable = false) + @XmlElement(required = true, nillable = false, name="inputData") public byte[] getInputData() { return inputData; } @@ -33,7 +35,7 @@ public class PDFASSignRequest implements Serializable { this.inputData = inputData; } - @XmlElement(required = true, nillable = false) + @XmlElement(required = true, nillable = false, name="parameters") public PDFASSignParameters getParameters() { return parameters; } diff --git a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignResponse.java b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignResponse.java index a27d1afe..1da4fa98 100644 --- a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignResponse.java +++ b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSignResponse.java @@ -3,7 +3,9 @@ package at.gv.egiz.pdfas.api.ws; import java.io.Serializable; import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlType; +@XmlType(name="SignResponse") public class PDFASSignResponse implements Serializable { /** @@ -15,7 +17,7 @@ public class PDFASSignResponse implements Serializable { String error; byte[] signedPDF; - @XmlElement(required = true, nillable = false) + @XmlElement(required = true, nillable = false, name="requestID") public String getRequestID() { return requestID; } @@ -23,7 +25,7 @@ public class PDFASSignResponse implements Serializable { this.requestID = requestID; } - @XmlElement(required = false, nillable = false) + @XmlElement(required = false, nillable = false, name="signedPDF") public byte[] getSignedPDF() { return signedPDF; } @@ -31,7 +33,7 @@ public class PDFASSignResponse implements Serializable { this.signedPDF = signedPDF; } - @XmlElement(required = false) + @XmlElement(required = false, name="error") public String getError() { return error; } diff --git a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSigning.java b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSigning.java index 5d283cf7..63049bc5 100644 --- a/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSigning.java +++ b/pdf-as-common/src/main/java/at/gv/egiz/pdfas/api/ws/PDFASSigning.java @@ -2,6 +2,7 @@ package at.gv.egiz.pdfas.api.ws; import javax.jws.WebMethod; import javax.jws.WebParam; +import javax.jws.WebResult; import javax.jws.WebService; import javax.jws.soap.SOAPBinding; import javax.jws.soap.SOAPBinding.Style; @@ -10,11 +11,14 @@ import javax.jws.soap.SOAPBinding.Style; @SOAPBinding(style = Style.RPC) public interface PDFASSigning { @WebMethod(operationName = "sign") + @WebResult(name="signedPDF") public byte[] signPDFDokument(@WebParam(name = "pdfDocument")byte[] inputDocument, @WebParam(name = "parameters")PDFASSignParameters parameters); @WebMethod(operationName = "signSingle") + @WebResult(name="signResponse") public PDFASSignResponse signPDFDokument(@WebParam(name = "signRequest") PDFASSignRequest request); @WebMethod(operationName = "signBulk") - public PDFASSignResponse[] signPDFDokument(@WebParam(name = "signRequests") PDFASSignRequest[] request); + @WebResult(name="bulkResponse") + public PDFASBulkSignResponse signPDFDokument(@WebParam(name = "signBulkRequest") PDFASBulkSignRequest request); } |