Class SpringAwareMessageDecoderFactory
java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
net.shibboleth.idp.saml.profile.impl.SpringAwareMessageDecoderFactory
- All Implemented Interfaces:
Function<String,,MessageDecoder> Component,DestructableComponent,InitializableComponent,Aware,ApplicationContextAware
@ThreadSafeAfterInit
public class SpringAwareMessageDecoderFactory
extends AbstractInitializableComponent
implements Function<String,MessageDecoder>, ApplicationContextAware
A function that returns the correct
MessageDecoder to use based on a simple map of
strings to bean IDs.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ApplicationContextApplication context injected by surroundings.Map of strings to bean IDs.private final org.slf4j.LoggerClass logger. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidsetApplicationContext(ApplicationContext context) voidsetBeanMappings(Map<String, String> mappings) Set mappings of strings to names ofMessageDecoderbeans.Methods inherited from class net.shibboleth.shared.component.AbstractInitializableComponent
checkComponentActive, checkSetterPreconditions, destroy, doDestroy, doInitialize, ifDestroyedThrowDestroyedComponentException, ifInitializedThrowUnmodifiabledComponentException, ifNotInitializedThrowUninitializedComponentException, initialize, isDestroyed, isInitialized
-
Field Details
-
log
@Nonnull private final org.slf4j.Logger logClass logger. -
applicationContext
Application context injected by surroundings. -
beanMappings
Map of strings to bean IDs.
-
-
Constructor Details
-
SpringAwareMessageDecoderFactory
public SpringAwareMessageDecoderFactory()Constructor.
-
-
Method Details
-
setBeanMappings
Set mappings of strings to names ofMessageDecoderbeans.- Parameters:
mappings- string to bean ID mappings
-
setApplicationContext
- Specified by:
setApplicationContextin interfaceApplicationContextAware
-
apply
- Specified by:
applyin interfaceFunction<String,MessageDecoder>
-