* @param messageID ID of message to retrieve
* @return message found or null
*/
public XMLObject retrieveMessage(String messageID) {
Hashtable<String, SAMLObject<XMLObject>> messages = getMessages();
SAMLObject o = messages.get(messageID);
if (o == null) {
log.debug("Message {} not found in session {}", messageID, session.getId());
return null;
} else {
log.debug("Message {} found in session {}, clearing", messageID, session.getId());
messages.clear();
updateSession(messages);
return o.getObject();
}
}