From 53ae98cdfa510650c1e015efd0d11a96ad4dc87a Mon Sep 17 00:00:00 2001 From: Andreas Fitzek Date: Mon, 20 Jun 2016 12:45:07 +0200 Subject: ASiC Library added --- .../spss/api/xmlbind/VerifyCMSSignatureResponseBuilder.java | 12 ++++++++++++ .../spss/api/xmlbind/VerifyXMLSignatureResponseBuilder.java | 10 ++++++++++ 2 files changed, 22 insertions(+) (limited to 'moaSig/moa-sig-lib/src/main/java/at/gv') diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyCMSSignatureResponseBuilder.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyCMSSignatureResponseBuilder.java index 6c4667b..5bc7bec 100644 --- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyCMSSignatureResponseBuilder.java +++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyCMSSignatureResponseBuilder.java @@ -26,6 +26,8 @@ package at.gv.egovernment.moa.spss.api.xmlbind; import java.util.Iterator; +import at.gv.egovernment.moa.spss.api.xmlverify.VerifyXMLSignatureResponse; +import at.gv.egovernment.moaspss.util.Constants; import org.w3c.dom.Document; import org.w3c.dom.Element; @@ -61,6 +63,16 @@ public class VerifyCMSSignatureResponseBuilder { ResponseBuilderUtils.createResponse("VerifyCMSSignatureResponse"); responseElem = responseDoc.getDocumentElement(); } + + public VerifyCMSSignatureResponseBuilder(Document responseDoc, String name) throws MOASystemException { + this.responseDoc = responseDoc; + responseElem = responseDoc.createElementNS(Constants.MOA_NS_URI, name); + } + + public Element buildElement(VerifyCMSSignatureResponse response) throws MOAApplicationException { + this.build(response); + return responseElem; + } /** * Build a document containing a VerifyCMSSignatureResponse diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyXMLSignatureResponseBuilder.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyXMLSignatureResponseBuilder.java index 5329861..771c276 100644 --- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyXMLSignatureResponseBuilder.java +++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/api/xmlbind/VerifyXMLSignatureResponseBuilder.java @@ -74,6 +74,16 @@ public class VerifyXMLSignatureResponseBuilder { responseElem = responseDoc.getDocumentElement(); } + public VerifyXMLSignatureResponseBuilder(Document responseDoc, String name) throws MOASystemException { + this.responseDoc = responseDoc; + responseElem = responseDoc.createElementNS(MOA_NS_URI, name); + } + + public Element buildElement(VerifyXMLSignatureResponse response) throws MOAApplicationException { + this.build(response); + return responseElem; + } + /** * Build a document containing a VerifyXMLSignatureResponse DOM * element being the XML representation of the given -- cgit v1.2.3