Example usage for javax.xml.crypto XMLCryptoContext getURIDereferencer

List of usage examples for javax.xml.crypto XMLCryptoContext getURIDereferencer

Introduction

In this page you can find the example usage for javax.xml.crypto XMLCryptoContext getURIDereferencer.

Prototype

URIDereferencer getURIDereferencer();

Source Link

Document

Returns a URIDereferencer that is used to dereference URIReference s.

Usage

From source file:org.apache.jcp.xml.dsig.internal.dom.DOMReference.java

private Data dereference(XMLCryptoContext context) throws XMLSignatureException {
    Data data = null;/*from   w  ww.  j  ava2s . co m*/

    // use user-specified URIDereferencer if specified; otherwise use deflt
    URIDereferencer deref = context.getURIDereferencer();
    if (deref == null) {
        deref = DOMURIDereferencer.INSTANCE;
    }
    try {
        data = deref.dereference(this, context);
        if (log.isDebugEnabled()) {
            log.debug("URIDereferencer class name: " + deref.getClass().getName());
            log.debug("Data class name: " + data.getClass().getName());
        }
    } catch (URIReferenceException ure) {
        throw new XMLSignatureException(ure);
    }

    return data;
}