public class RequestContextBuilder extends Object
RequestContext used in Action
executions.| Modifier and Type | Field and Description |
|---|---|
private HttpServletRequest |
httpRequest
The
HttpServletRequest used when building the request context. |
private HttpServletResponse |
httpResponse
The
HttpServletResponse used when building the request context. |
private Object |
inboundMessage
The inbound message.
|
private String |
inboundMessageId
The ID of the inbound message.
|
private long |
inboundMessageIssueInstant
The issue instant of the inbound message in milliseconds.
|
private String |
inboundMessageIssuer
The issuer of the inbound message.
|
private String |
NO_VAL
Value used to represent a string value that has not be set.
|
private Object |
outboundMessage
The outbound message.
|
private String |
outboundMessageId
The ID of the outbound message.
|
private long |
outboundMessageIssueInstant
The issue instant of the outbound message in milliseconds.
|
private String |
outboundMessageIssuer
The issuer of the outbound message.
|
private Collection<net.shibboleth.idp.profile.config.ProfileConfiguration> |
relyingPartyProfileConfigurations
The profile configurations associated with the relying party.
|
private ServletContext |
servletContext
The
ServletContext used when building the request context. |
| Constructor and Description |
|---|
RequestContextBuilder()
Constructor.
|
RequestContextBuilder(RequestContextBuilder prototype)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected org.opensaml.messaging.context.MessageContext |
buildInboundMessageContext()
Builds a inbound
MessageContext. |
protected org.opensaml.messaging.context.MessageContext |
buildOutboundMessageContext()
Builds a outbound
MessageContext. |
org.opensaml.profile.context.ProfileRequestContext |
buildProfileRequestContext()
Builds a
ProfileRequestContext. |
protected net.shibboleth.idp.relyingparty.RelyingPartyConfiguration |
buildRelyingPartyConfiguration()
Builds a
RelyingPartyConfiguration. |
protected net.shibboleth.idp.profile.context.RelyingPartyContext |
buildRelyingPartyContext(org.opensaml.profile.context.ProfileRequestContext profileRequestContext)
Builds
RelyingPartyContext. |
org.springframework.webflow.execution.RequestContext |
buildRequestContext()
Builds a
MockRequestContext. |
org.springframework.webflow.context.servlet.ServletExternalContext |
buildServletExternalContext()
Builds a
ServletExternalContext. |
protected net.shibboleth.idp.profile.config.ProfileConfiguration |
selectProfileConfiguration(Map<String,net.shibboleth.idp.profile.config.ProfileConfiguration> rpProfileConfigs)
Selects the active profile configurations from the set of registered profile configuration from the relying party
configuration built by
buildRelyingPartyConfiguration(). |
RequestContextBuilder |
setHttpRequest(HttpServletRequest request)
Sets the
HttpServletRequest used when building the request context. |
RequestContextBuilder |
setHttpResponse(HttpServletResponse response)
Sets the
HttpServletResponse used when building the request context. |
RequestContextBuilder |
setInboundMessage(Object message)
Sets the inbound message.
|
RequestContextBuilder |
setInboundMessageId(String id)
Sets the ID of the inbound message.
|
RequestContextBuilder |
setInboundMessageIssueInstant(long instant)
Sets the issue instant of the inbound message in milliseconds.
|
RequestContextBuilder |
setInboundMessageIssuer(String issuer)
Sets the issuer of the inbound message.
|
RequestContextBuilder |
setOutboundMessage(Object message)
Sets the outbound message.
|
RequestContextBuilder |
setOutboundMessageId(String id)
Sets the ID of the outbound message.
|
RequestContextBuilder |
setOutboundMessageIssueInstant(long instant)
Sets the issue instant of the outbound message in milliseconds.
|
RequestContextBuilder |
setOutboundMessageIssuer(String issuer)
Sets the issuer of the outbound message.
|
RequestContextBuilder |
setRelyingPartyProfileConfigurations(Collection<net.shibboleth.idp.profile.config.ProfileConfiguration> configs)
Sets the profile configurations associated with the relying party.
|
RequestContextBuilder |
setServletContext(ServletContext context)
Sets the
ServletContext used when building the request context. |
private final String NO_VAL
private ServletContext servletContext
ServletContext used when building the request context.private HttpServletRequest httpRequest
HttpServletRequest used when building the request context.private HttpServletResponse httpResponse
HttpServletResponse used when building the request context.private String inboundMessageId
private long inboundMessageIssueInstant
private String inboundMessageIssuer
private Object inboundMessage
private String outboundMessageId
private long outboundMessageIssueInstant
private String outboundMessageIssuer
private Object outboundMessage
private Collection<net.shibboleth.idp.profile.config.ProfileConfiguration> relyingPartyProfileConfigurations
public RequestContextBuilder()
public RequestContextBuilder(RequestContextBuilder prototype)
prototype - prototype whose properties are copied onto this builder@Nonnull public RequestContextBuilder setServletContext(@Nullable ServletContext context)
ServletContext used when building the request context.context - the ServletContext used when building the request context@Nonnull public RequestContextBuilder setHttpRequest(@Nullable HttpServletRequest request)
HttpServletRequest used when building the request context.request - the HttpServletRequest used when building the request context@Nonnull public RequestContextBuilder setHttpResponse(@Nullable HttpServletResponse response)
HttpServletResponse used when building the request context.response - the HttpServletResponse used when building the request context@Nonnull public RequestContextBuilder setInboundMessageId(@Nullable String id)
id - ID of the inbound message@Nonnull public RequestContextBuilder setInboundMessageIssueInstant(long instant)
instant - issue instant of the inbound message in milliseconds@Nonnull public RequestContextBuilder setInboundMessageIssuer(@Nullable String issuer)
issuer - issuer of the inbound message@Nonnull public RequestContextBuilder setInboundMessage(@Nullable Object message)
message - the inbound message@Nonnull public RequestContextBuilder setOutboundMessageId(@Nullable String id)
id - ID of the outbound message@Nonnull public RequestContextBuilder setOutboundMessageIssueInstant(long instant)
instant - issue instant of the outbound message in millisecondspublic RequestContextBuilder setOutboundMessageIssuer(@Nullable String issuer)
issuer - issuer of the outbound message@Nonnull public RequestContextBuilder setOutboundMessage(@Nullable Object message)
message - the outbound message@Nonnull public RequestContextBuilder setRelyingPartyProfileConfigurations(@Nullable Collection<net.shibboleth.idp.profile.config.ProfileConfiguration> configs)
configs - profile configurations associated with the relying party@Nonnull public org.springframework.webflow.execution.RequestContext buildRequestContext() throws net.shibboleth.utilities.java.support.component.ComponentInitializationException
MockRequestContext.
The default implementation builds a MockRequestContext that contains a:
ServletExternalContext, via
RequestContext.getExternalContext(), created by
buildServletExternalContext()ProfileRequestContext created by buildProfileRequestContext()MockRequestContextnet.shibboleth.utilities.java.support.component.ComponentInitializationException@Nonnull public org.springframework.webflow.context.servlet.ServletExternalContext buildServletExternalContext()
ServletExternalContext.
The default implementations builds a ServletExternalContext that contains a:
ServletContext provided by setServletContext(ServletContext) or a
MockServletContext if none was providedHttpServletRequest provided by setHttpRequest(HttpServletRequest) or a
MockHttpServletRequest if none was providedHttpServletResponse provided by setHttpResponse(HttpServletResponse) or a
MockHttpServletResponse if none was providedServletContext@Nonnull public org.opensaml.profile.context.ProfileRequestContext buildProfileRequestContext() throws net.shibboleth.utilities.java.support.component.ComponentInitializationException
ProfileRequestContext.
The default implementation builds a ProfileRequestContext that contains a:
buildInboundMessageContext()buildOutboundMessageContext()RelyingPartyContext created by #buildRelyingPartyContext()net.shibboleth.utilities.java.support.component.ComponentInitializationException - @link ProfileRequestContext@Nonnull protected org.opensaml.messaging.context.MessageContext buildInboundMessageContext()
MessageContext.
The default implementation builds a MessageContext that contains:
setInboundMessage(Object)BasicMessageMetadataContext created by #buildInboudMessageMetadataContext(MessageContext)MessageContext@Nonnull protected org.opensaml.messaging.context.MessageContext buildOutboundMessageContext()
MessageContext.
The default implementation builds a MessageContext that contains:
setOutboundMessage(Object)BasicMessageMetadataContext created by #buildOutboudMessageMetadataContext(MessageContext)MessageContext@Nonnull protected net.shibboleth.idp.profile.context.RelyingPartyContext buildRelyingPartyContext(@Nonnull org.opensaml.profile.context.ProfileRequestContext profileRequestContext) throws net.shibboleth.utilities.java.support.component.ComponentInitializationException
RelyingPartyContext.
The default implementations builds a RelyingPartyContext with:
setInboundMessageIssuer(String) or
ActionTestingSupport.INBOUND_MSG_ISSUER if none is givenbuildRelyingPartyConfiguration()selectProfileConfiguration(Map)RelyingPartyContextnet.shibboleth.utilities.java.support.component.ComponentInitializationException@Nonnull protected net.shibboleth.idp.relyingparty.RelyingPartyConfiguration buildRelyingPartyConfiguration() throws net.shibboleth.utilities.java.support.component.ComponentInitializationException
RelyingPartyConfiguration.
The default implementation of this method builds a RelyingPartyConfiguration such that:
setOutboundMessageIssuer(String) or
ActionTestingSupport.OUTBOUND_MSG_ISSUER if none is givenPredicates.alwaysTrue()setRelyingPartyProfileConfigurations(Collection) or one
MockProfileConfiguration if none is providedRelyingPartyConfigurationnet.shibboleth.utilities.java.support.component.ComponentInitializationException@Nullable protected net.shibboleth.idp.profile.config.ProfileConfiguration selectProfileConfiguration(@Nonnull Map<String,net.shibboleth.idp.profile.config.ProfileConfiguration> rpProfileConfigs)
buildRelyingPartyConfiguration().
The default implementation of this method simply returns the first value of the Map.values() collection.rpProfileConfigs - the set of profile configurations associated with the constructed relying partyProfileConfigurationCopyright © 1999–2014. All rights reserved.