Package net.shibboleth.idp.attribute.config

# Class AbstractCollectionConfigurationLookupStrategy<T1,T2>

java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
net.shibboleth.idp.attribute.config.AbstractMetadataDrivenConfigurationLookupStrategy<T2>
net.shibboleth.idp.attribute.config.AbstractCollectionConfigurationLookupStrategy<T1,T2>

Type Parameters:
  `T1` - type of collection member
  `T2` - type of collection itself

All Implemented Interfaces:
  `Function<BaseContext,T2>`, `Component`, `DestructableComponent`, `InitializableComponent`

Direct Known Subclasses:
  `ListConfigurationLookupStrategy`, `SetConfigurationLookupStrategy`

public abstract class AbstractCollectionConfigurationLookupStrategy<T1,T2> extends AbstractMetadataDrivenConfigurationLookupStrategy<T2>
A strategy function that examines SAML metadata associated with a relying party and derives List<String>-valued configuration settings based on EntityAttribute extension tags.

Since:
  5.0.0

## Nested Class Summary

## Nested classes/interfaces inherited from class net.shibboleth.idp.attribute.config.AbstractMetadataDrivenConfigurationLookupStrategy

`AbstractMetadataDrivenConfigurationLookupStrategy.CachedConfigurationContext`

## Field Summary

Fields
Modifier and Type
Field
Description
`private static final org.slf4j.Logger`
`LOG`
Class logger.
`private Class<T1>`
`propertyType`
Type of bean in collection.

## Constructor Summary

Constructors
Constructor
Description
`AbstractCollectionConfigurationLookupStrategy()`

## Method Summary

Modifier and Type
Method
Description
`protected T1`
`createInstanceFromString(String input)`
Helper method to manufacture instance of object using a string constructor or a cast.
`protected void`
`doInitialize()`
`Class<T1>`
`getPropertyType()`
Get the type of object to coerce collection elements into.
`void`
`setPropertyType(Class<T1> type)`
Set the type of object to coerce collection elements into.
`protected String`
`xmlObjectToString(XMLObject object)`
Convert an XMLObject to a String if the type is supported.

### Methods inherited from class net.shibboleth.idp.attribute.config.AbstractMetadataDrivenConfigurationLookupStrategy

`apply, doTranslate, doTranslate, setDefaultValue, setDefaultValueStrategy, setEnableCaching, setExplicitPropertyName, setIgnoreUnmappedEntityAttributes, setLegacyPropertyName, setMessageMetadataLookupStrategy, setProfileAliases, setProfileIdLookupStrategy, setProfileMetadataLookupStrategy, setPropertyName, setStrictNameFormat`

### Methods inherited from class net.shibboleth.shared.component.AbstractInitializableComponent

`checkComponentActive, checkSetterPreconditions, destroy, doDestroy, ifDestroyedThrowDestroyedComponentException, ifInitializedThrowUnmodifiabledComponentException, ifNotInitializedThrowUninitializedComponentException, initialize, isDestroyed, isInitialized`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface java.util.function.Function

`andThen, compose`

## Field Details

### LOG

@Nonnull private static final org.slf4j.Logger LOG
Class logger.

### propertyType

@NonnullAfterInit private Class<T1> propertyType
Type of bean in collection.

## Constructor Details

### AbstractCollectionConfigurationLookupStrategy

public AbstractCollectionConfigurationLookupStrategy()

## Method Details

### getPropertyType

@NonnullAfterInit public Class<T1> getPropertyType()
Get the type of object to coerce collection elements into.

Returns:
  object type

### setPropertyType

public void setPropertyType(@Nonnull Class<T1> type)
Set the type of object to coerce collection elements into.

Parameters:
  `type` - object type

### doInitialize

protected void doInitialize() throws ComponentInitializationException

Overrides:
  `doInitialize` in class `AbstractMetadataDrivenConfigurationLookupStrategy<T2>`
Throws:
  `ComponentInitializationException`

### createInstanceFromString

@Nonnull protected T1 createInstanceFromString(@Nonnull @NotEmpty String input) throws ReflectiveOperationException
Helper method to manufacture instance of object using a string constructor or a cast.

Parameters:
  `input` - the input string
Returns:
  the new object or the existing object if casting is possible
Throws:
  `ReflectiveOperationException` - if the attempt fails

### xmlObjectToString

@Nullable protected String xmlObjectToString(@Nonnull XMLObject object)
Convert an XMLObject to a String if the type is supported.

Parameters:
  `object` - object to convert
Returns:
  the converted value, or null