public class SAMLAddAttributeConsumingServiceHandler extends AbstractMessageHandler
MessageHandler
that attaches an AttributeConsumingServiceContext
to the SAMLMetadataContext
based on the content of an AuthnRequest
in the message context.Constructor and Description |
---|
SAMLAddAttributeConsumingServiceHandler()
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
doInvoke(MessageContext messageContext)
Performs the handler logic.
|
protected boolean |
doPreInvoke(MessageContext messageContext)
Called prior to execution, handlers may override this method to perform pre-processing for a request.
|
void |
setIndexLookupStrategy(com.google.common.base.Function<MessageContext,Integer> strategy)
Set the strategy to locate the
AttributeConsumingService index from the MessageContext . |
void |
setMetadataContextLookupStrategy(com.google.common.base.Function<MessageContext,SAMLMetadataContext> strategy)
Set the strategy to locate the
SAMLMetadataContext from the MessageContext . |
doPostInvoke, doPostInvoke, getLogPrefix, invoke
destroy, doDestroy, doInitialize, initialize, isDestroyed, isInitialized
public SAMLAddAttributeConsumingServiceHandler()
public void setMetadataContextLookupStrategy(@Nonnull com.google.common.base.Function<MessageContext,SAMLMetadataContext> strategy)
SAMLMetadataContext
from the MessageContext
.strategy
- lookup strategypublic void setIndexLookupStrategy(@Nullable com.google.common.base.Function<MessageContext,Integer> strategy)
AttributeConsumingService
index from the MessageContext
.strategy
- lookup strategyprotected boolean doPreInvoke(@Nonnull MessageContext messageContext) throws MessageHandlerException
If false is returned, execution will not proceed.
If returning successfully, the last step should be to return the result of the superclass version of this method.
doPreInvoke
in class AbstractMessageHandler
messageContext
- the message context on which to invoke the handlerMessageHandlerException
- if there is a problem executing the handler pre-routineprotected void doInvoke(@Nonnull MessageContext messageContext) throws MessageHandlerException
doInvoke
in class AbstractMessageHandler
messageContext
- the message context on which to invoke the handlerMessageHandlerException
- if there is an error invoking the handler on the message contextCopyright © 2018. All rights reserved.