Search in sources :

Example 1 with XmlCompleteCertificateRefsType

use of xades4j.xml.bind.xades.XmlCompleteCertificateRefsType in project xades4j by luisgoncalves.

the class FromXmlCompleteCertRefsConverter method convertFromObjectTree.

@Override
public void convertFromObjectTree(XmlUnsignedSignaturePropertiesType xmlProps, QualifyingPropertiesDataCollector propertyDataCollector) throws PropertyUnmarshalException {
    XmlCompleteCertificateRefsType xmlCompleteCertRefs = xmlProps.getCompleteCertificateRefs();
    if (null == xmlCompleteCertRefs)
        return;
    CompleteCertificateRefsData completeCertRefsData = new CompleteCertificateRefsData();
    FromXmlUtils.createAndCertificateRefs(xmlCompleteCertRefs.getCertRefs(), completeCertRefsData);
    propertyDataCollector.setCompleteCertificateRefs(completeCertRefsData);
}
Also used : XmlCompleteCertificateRefsType(xades4j.xml.bind.xades.XmlCompleteCertificateRefsType) CompleteCertificateRefsData(xades4j.properties.data.CompleteCertificateRefsData)

Example 2 with XmlCompleteCertificateRefsType

use of xades4j.xml.bind.xades.XmlCompleteCertificateRefsType in project xades4j by luisgoncalves.

the class ToXmlCompleteCertRefsConverter method convertIntoObjectTree.

@Override
public void convertIntoObjectTree(PropertyDataObject propData, XmlUnsignedPropertiesType xmlProps, Document doc) {
    XmlCertIDListType xmlCertRefsList = ToXmlUtils.getXmlCertRefList((CompleteCertificateRefsData) propData);
    XmlCompleteCertificateRefsType xmlCompleteCertRefsProp = new XmlCompleteCertificateRefsType();
    xmlCompleteCertRefsProp.setCertRefs(xmlCertRefsList);
    xmlProps.getUnsignedSignatureProperties().setCompleteCertificateRefs(xmlCompleteCertRefsProp);
}
Also used : XmlCertIDListType(xades4j.xml.bind.xades.XmlCertIDListType) XmlCompleteCertificateRefsType(xades4j.xml.bind.xades.XmlCompleteCertificateRefsType)

Aggregations

XmlCompleteCertificateRefsType (xades4j.xml.bind.xades.XmlCompleteCertificateRefsType)2 CompleteCertificateRefsData (xades4j.properties.data.CompleteCertificateRefsData)1 XmlCertIDListType (xades4j.xml.bind.xades.XmlCertIDListType)1