// End Element for KeyIdentifier
canonWriter.writeEndElement();
}
reader.next();
//resolve Key.
URIResolver resolver = new URIResolver(pc);
JAXBValidateContext validateContext = new JAXBValidateContext();
validateContext.setURIDereferencer(resolver);
validateContext.put(MessageConstants.WSS_PROCESSING_CONTEXT, pc);
return KeySelectorImpl.resolveKeyIdentifier(validateContext,valueType,keyIdentifier,id,purpose);
}catch(KeySelectorException kse){