Package net.shibboleth.idp.saml.metadata.impl

# Class ByReferenceMetadataFilterBridge

java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
org.opensaml.saml.metadata.resolver.filter.AbstractMetadataFilter
net.shibboleth.idp.saml.metadata.impl.ByReferenceMetadataFilterBridge

All Implemented Interfaces:
  `Component`, `DestructableComponent`, `InitializableComponent`, `MetadataFilter`, `Aware`, `ApplicationContextAware`

public class ByReferenceMetadataFilterBridge extends AbstractMetadataFilter implements ApplicationContextAware
This is a bridge filter that uses Spring to locate extant `ByReferenceMetadataFilter` objects to run.

## Field Summary

Fields
Modifier and Type
Field
Description
`private ApplicationContext`
`applicationContext`
Application context.
`private boolean`
`enabled`
Whether to actually enable this filter.
`private MetadataFilterChain`
`filterChain`
Chain to wrap the beans obtained from the context.
`private final org.slf4j.Logger`
`log`
Class logger.

## Constructor Summary

Constructors
Constructor
Description
`ByReferenceMetadataFilterBridge()`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`XMLObject`
`filter(XMLObject metadata, MetadataFilterContext context)`
`void`
`setApplicationContext(ApplicationContext context)`
Set the containing `ApplicationContext`.
`void`
`setEnabled(boolean flag)`
Sets whether to enable this filter.

### Methods inherited from class org.opensaml.saml.metadata.resolver.filter.AbstractMetadataFilter

`getType, setType`

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

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

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

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

## Field Details

### log

@Nonnull private final org.slf4j.Logger log
Class logger.

### enabled

private boolean enabled
Whether to actually enable this filter.

### applicationContext

@Nullable private ApplicationContext applicationContext
Application context.

### filterChain

@Nullable private MetadataFilterChain filterChain
Chain to wrap the beans obtained from the context.

## Constructor Details

### ByReferenceMetadataFilterBridge

public ByReferenceMetadataFilterBridge()
Constructor.

## Method Details

### setEnabled

public void setEnabled(boolean flag)
Sets whether to enable this filter.

Defaults to true.

Parameters:
  `flag` - flag to set

### setApplicationContext

public void setApplicationContext(@Nullable ApplicationContext context)
Set the containing `ApplicationContext`.

Specified by:
  `setApplicationContext` in interface `ApplicationContextAware`
Parameters:
  `context` - the context

### filter

@Nullable public XMLObject filter(@Nullable XMLObject metadata, @Nonnull MetadataFilterContext context) throws FilterException

Specified by:
  `filter` in interface `MetadataFilter`
Throws:
  `FilterException`