public class RelyingPartyConfiguration extends AbstractIdentifiableInitializableComponent implements IdentifiedComponent, com.google.common.base.Predicate<ProfileRequestContext>
| Modifier and Type | Field and Description |
|---|---|
private com.google.common.base.Predicate<ProfileRequestContext> |
activationCondition
Predicate that must be true for this configuration to be active for a given request.
|
private com.google.common.base.Predicate<ProfileRequestContext> |
detailedErrorsPredicate
Controls whether detailed information about errors should be exposed.
|
private org.slf4j.Logger |
log
Class logger.
|
private Map<String,ProfileConfiguration> |
profileConfigurations
Registered and usable communication profile configurations for this relying party.
|
private com.google.common.base.Function<ProfileRequestContext,Map<String,ProfileConfiguration>> |
profileConfigurationsLookupStrategy
Lookup function to supply
profileConfigurations property. |
private String |
responderId
Self-referential ID to use when responding to messages.
|
private com.google.common.base.Function<ProfileRequestContext,String> |
responderIdLookupStrategy
Lookup function to supply
responderId property. |
private javax.servlet.ServletRequest |
servletRequest
Access to servlet request.
|
| Constructor and Description |
|---|
RelyingPartyConfiguration()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
apply(ProfileRequestContext input) |
protected void |
doInitialize() |
com.google.common.base.Predicate<ProfileRequestContext> |
getDetailedErrorsPredicate()
Get a condition to determine whether detailed information about errors should be exposed.
|
protected <T> T |
getIndirectProperty(com.google.common.base.Function<ProfileRequestContext,T> lookupStrategy,
T staticValue)
Get a property, possibly through indirection via a lookup function.
|
ProfileConfiguration |
getProfileConfiguration(String profileId)
Get the profile configuration, for the relying party, for the given profile.
|
Map<String,ProfileConfiguration> |
getProfileConfigurations()
Get the unmodifiable set of profile configurations for this relying party.
|
protected ProfileRequestContext |
getProfileRequestContext()
Get the current
ProfileRequestContext. |
String |
getResponderId()
Get the self-referential ID to use when responding to requests.
|
boolean |
isDetailedErrors()
Deprecated.
Use
getDetailedErrorsPredicate() instead. |
void |
setActivationCondition(com.google.common.base.Predicate<ProfileRequestContext> condition)
Set the condition under which the relying party configuration should be active.
|
void |
setDetailedErrors(boolean flag)
Set whether detailed information about errors should be exposed.
|
void |
setDetailedErrorsPredicate(com.google.common.base.Predicate<ProfileRequestContext> condition)
Set a condition to determine whether detailed information about errors should be exposed.
|
void |
setProfileConfigurations(Collection<ProfileConfiguration> configs)
Set the profile configurations for this relying party.
|
void |
setProfileConfigurationsLookupStrategy(com.google.common.base.Function<ProfileRequestContext,Map<String,ProfileConfiguration>> strategy)
Set a lookup strategy for the
profileConfigurations property. |
void |
setResponderId(String responder)
Set the self-referential ID to use when responding to messages.
|
void |
setResponderIdLookupStrategy(com.google.common.base.Function<ProfileRequestContext,String> strategy)
Set a lookup strategy for the
responderId property. |
void |
setServletRequest(javax.servlet.ServletRequest request)
Set the
ServletRequest from which to obtain a reference to the current ProfileRequestContext. |
setIdgetIddestroy, doDestroy, initialize, isDestroyed, isInitializedclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetId@Nonnull private final org.slf4j.Logger log
@Nullable private javax.servlet.ServletRequest servletRequest
@Nullable private com.google.common.base.Function<ProfileRequestContext,String> responderIdLookupStrategy
responderId property.@Nullable @NotEmpty private String responderId
@Nonnull private com.google.common.base.Predicate<ProfileRequestContext> detailedErrorsPredicate
@Nullable private com.google.common.base.Function<ProfileRequestContext,Map<String,ProfileConfiguration>> profileConfigurationsLookupStrategy
profileConfigurations property.@Nonnull @NonnullElements private Map<String,ProfileConfiguration> profileConfigurations
@Nonnull private com.google.common.base.Predicate<ProfileRequestContext> activationCondition
public void setServletRequest(@Nullable javax.servlet.ServletRequest request)
ServletRequest from which to obtain a reference to the current ProfileRequestContext.
Generally this would be expected to be a proxy to the actual object.
request - servlet request@Nonnull @NotEmpty public String getResponderId()
public void setResponderId(@Nullable String responder)
responder - ID to use when responding to messagespublic void setResponderIdLookupStrategy(@Nullable com.google.common.base.Function<ProfileRequestContext,String> strategy)
responderId property.strategy - lookup strategypublic boolean isDetailedErrors()
getDetailedErrorsPredicate() instead.public void setDetailedErrors(boolean flag)
flag - flag to set@Nonnull public com.google.common.base.Predicate<ProfileRequestContext> getDetailedErrorsPredicate()
public void setDetailedErrorsPredicate(@Nonnull com.google.common.base.Predicate<ProfileRequestContext> condition)
condition - condition to set@Nonnull @NonnullElements @Unmodifiable @NotLive public Map<String,ProfileConfiguration> getProfileConfigurations()
@Nullable public ProfileConfiguration getProfileConfiguration(@Nullable String profileId)
Map.get(Object) on the return of getProfileConfigurations(). This map
contains no null entries, keys, or values.profileId - the ID of the profilepublic void setProfileConfigurations(@Nullable@NonnullElements Collection<ProfileConfiguration> configs)
configs - the configurations to setpublic void setProfileConfigurationsLookupStrategy(@Nullable com.google.common.base.Function<ProfileRequestContext,Map<String,ProfileConfiguration>> strategy)
profileConfigurations property.strategy - lookup strategypublic void setActivationCondition(@Nonnull com.google.common.base.Predicate<ProfileRequestContext> condition)
condition - the activation conditionprotected void doInitialize()
throws ComponentInitializationException
doInitialize in class AbstractIdentifiedInitializableComponentComponentInitializationExceptionpublic boolean apply(@Nullable ProfileRequestContext input)
apply in interface com.google.common.base.Predicate<ProfileRequestContext>@Nullable protected ProfileRequestContext getProfileRequestContext()
ProfileRequestContext.@Nullable protected <T> T getIndirectProperty(@Nullable com.google.common.base.Function<ProfileRequestContext,T> lookupStrategy, @Nullable T staticValue)
T - type of propertylookupStrategy - lookup strategy function for indirect accessstaticValue - static value to return in the absence of a lookup function or if null is returnedCopyright © 1999–2018 Shibboleth Consortium. All rights reserved.