Class BeanConfigurationLookupStrategy<T>
java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
net.shibboleth.idp.attribute.config.AbstractMetadataDrivenConfigurationLookupStrategy<T>
net.shibboleth.idp.attribute.config.BeanConfigurationLookupStrategy<T>
- Type Parameters:
T- type of bean
- All Implemented Interfaces:
Function<BaseContext,,T> Component,DestructableComponent,InitializableComponent,Aware,ApplicationContextAware
public class BeanConfigurationLookupStrategy<T>
extends AbstractMetadataDrivenConfigurationLookupStrategy<T>
implements ApplicationContextAware
A strategy function that examines SAML metadata associated with a relying party and derives bean-based
configuration settings based on EntityAttribute extension tags.
Defaults to no caching of the result to avoid bean lifecycle issues if relying party config is reloaded.
- Since:
- 5.0.0
-
Nested Class Summary
Nested classes/interfaces inherited from class net.shibboleth.idp.attribute.config.AbstractMetadataDrivenConfigurationLookupStrategy
AbstractMetadataDrivenConfigurationLookupStrategy.CachedConfigurationContext -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ApplicationContextEnclosing Spring context.private static final org.slf4j.LoggerClass logger.Type of bean to return. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidprotected TdoTranslate(IdPAttribute tag) Translate the value(s) into a setting of the appropriate type.protected TdoTranslate(Attribute tag) Translate the value(s) into a setting of the appropriate type.voidsetApplicationContext(ApplicationContext context) voidsetPropertyType(Class<T> type) Set the type of bean to search for.private TxmlObjectToBean(XMLObject object) Convert an XMLObject to a Spring bean reference if the type is supported.Methods inherited from class net.shibboleth.idp.attribute.config.AbstractMetadataDrivenConfigurationLookupStrategy
apply, setDefaultValue, setDefaultValueStrategy, setEnableCaching, setExplicitPropertyName, setIgnoreUnmappedEntityAttributes, setLegacyPropertyName, setMessageMetadataLookupStrategy, setProfileAliases, setProfileIdLookupStrategy, setProfileMetadataLookupStrategy, setPropertyName, setStrictNameFormatMethods inherited from class net.shibboleth.shared.component.AbstractInitializableComponent
checkComponentActive, checkSetterPreconditions, destroy, doDestroy, ifDestroyedThrowDestroyedComponentException, ifInitializedThrowUnmodifiabledComponentException, ifNotInitializedThrowUninitializedComponentException, initialize, isDestroyed, isInitialized
-
Field Details
-
LOG
@Nonnull private static final org.slf4j.Logger LOGClass logger. -
applicationContext
Enclosing Spring context. -
propertyType
Type of bean to return.
-
-
Constructor Details
-
BeanConfigurationLookupStrategy
public BeanConfigurationLookupStrategy()Constructor.
-
-
Method Details
-
setPropertyType
Set the type of bean to search for.- Parameters:
type- bean type
-
setApplicationContext
- Specified by:
setApplicationContextin interfaceApplicationContextAware- Throws:
BeansException
-
doInitialize
- Overrides:
doInitializein classAbstractMetadataDrivenConfigurationLookupStrategy<T>- Throws:
ComponentInitializationException
-
doTranslate
Translate the value(s) into a setting of the appropriate type.Overrides of this function can assume a non-zero collection of values.
- Specified by:
doTranslatein classAbstractMetadataDrivenConfigurationLookupStrategy<T>- Parameters:
tag- tag to translate- Returns:
- the setting derived from the tag's value(s)
-
doTranslate
Translate the value(s) into a setting of the appropriate type.Overrides of this function can assume a non-zero collection of values.
- Specified by:
doTranslatein classAbstractMetadataDrivenConfigurationLookupStrategy<T>- Parameters:
tag- tag to translate- Returns:
- the setting derived from the tag's value(s)
-
xmlObjectToBean
Convert an XMLObject to a Spring bean reference if the type is supported.- Parameters:
object- object to convert- Returns:
- the converted value, or null
-