Package net.shibboleth.shared.spring.custom

# Class SecondaryNamespaceHandler

java.lang.Object
net.shibboleth.shared.spring.custom.SecondaryNamespaceHandler

public abstract class SecondaryNamespaceHandler extends Object
A secondary namespace handler to allow us to stack multiple parsers.

Since:
  7.0.0

## Field Summary

Fields
Modifier and Type
Field
Description
`private Map<QName,BeanDefinitionParser>`
`parsers`
Stores the `BeanDefinitionParser` implementations keyed by the local name of the `Elements` they handle.

## Constructor Summary

Constructors
Constructor
Description
`SecondaryNamespaceHandler()`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`abstract void`
`doInit()`
Subclasses implement this method and in it register the `BeanDefinitionParser`s via calls to `registerBeanDefinitionParser(QName, BeanDefinitionParser)`.
`protected void`
`init(Map<QName,BeanDefinitionParser> theParsers)`
Initialize the handler, called automatically as part of `BaseSpringNamespaceHandler.init()` if the secondary handler qualifier was specified during `BaseSpringNamespaceHandler(String)`.
`protected void`
`registerBeanDefinitionParser(QName elementNameOrType, BeanDefinitionParser parser)`
Subclasses call this to register the supplied `BeanDefinitionParser` to handle the specified element.

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

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

## Field Details

### parsers

@Nonnull private Map<QName,BeanDefinitionParser> parsers
Stores the `BeanDefinitionParser` implementations keyed by the local name of the `Elements` they handle.

## Constructor Details

### SecondaryNamespaceHandler

public SecondaryNamespaceHandler()
Constructor.

## Method Details

### init

protected void init(@Nonnull Map<QName,BeanDefinitionParser> theParsers)
Initialize the handler, called automatically as part of `BaseSpringNamespaceHandler.init()` if the secondary handler qualifier was specified during `BaseSpringNamespaceHandler(String)`.

Parameters:
  `theParsers` - the parsers to use.

### registerBeanDefinitionParser

protected void registerBeanDefinitionParser(@Nonnull QName elementNameOrType, @Nonnull BeanDefinitionParser parser)
Subclasses call this to register the supplied `BeanDefinitionParser` to handle the specified element. The element name is the local (non-namespace qualified) name.

Parameters:
  `elementNameOrType` - the element name or schema type the parser is for
  `parser` - the parser to register

### doInit

public abstract void doInit()
Subclasses implement this method and in it register the `BeanDefinitionParser`s via calls to `registerBeanDefinitionParser(QName, BeanDefinitionParser)`.