public abstract class AbstractMetadataProviderParser
extends org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser
urn:mace:shibboleth:2.0:metadata namespace.
This also handles the ambivalence of where the <MetadataProvider> can be found. If it is found inside a
<RelyingPartyGroup> or a <ChainingMetadataPRovider> then we just emit a MetadataResolver of the correct
type and the outer parsers will deal with the rest. If we are the top most element then we need to summon up a
RelyingPartyMetadataProvider and inject what we would usually create into that.| Modifier and Type | Field and Description |
|---|---|
static QName |
CHAINING_PROVIDER_ELEMENT_NAME
ChainingMetadataProviderElement name.
|
private org.slf4j.Logger |
log
Logger.
|
static QName |
METADATA_FILTER_ELEMENT_NAME
MetadataFilter Element name.
|
static String |
METADATA_NAMESPACE
Namespace for Metadata.
|
static QName |
RELYING_PARTY_GROUP_ELEMENT_NAME
RelyingPartyGroup Element name.
|
static String |
RP_NAMESPACE
Namespace for RelyingParty.
|
static String |
SECURITY_NAMESPACE
Namespace for Security.
|
static QName |
TRUST_ENGINE_ELEMENT_NAME
TrustEngine element name.
|
| Constructor and Description |
|---|
AbstractMetadataProviderParser() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
doNativeParse(Element element,
org.springframework.beans.factory.xml.ParserContext parserContext,
org.springframework.beans.factory.support.BeanDefinitionBuilder builder)
Parse the element into the provider builder.
|
protected void |
doParse(Element element,
org.springframework.beans.factory.xml.ParserContext parserContext,
org.springframework.beans.factory.support.BeanDefinitionBuilder builder) |
protected Class<? extends MetadataResolver> |
getBeanClass(Element element) |
protected abstract Class<? extends MetadataResolver> |
getNativeBeanClass(Element element)
Return the real class implement by this type.
|
private boolean |
isPresentNotChaining(Element element,
String attribute)
Handle attributes which are inappropriate for specific implementations.
|
private boolean |
isTopMost(Element element)
Is this the element at the top of the file? Yes, if it has no parent or if the parent is a RelyingPartyGroup.
|
private void |
processPredicateOptions(Element element,
org.springframework.beans.factory.xml.ParserContext parserContext,
org.springframework.beans.factory.support.BeanDefinitionBuilder builder)
Process predicate-related options.
|
doParse, getBeanClassName, getParentName, parseInternalpublic static final String SECURITY_NAMESPACE
public static final String RP_NAMESPACE
public static final String METADATA_NAMESPACE
public static final QName METADATA_FILTER_ELEMENT_NAME
public static final QName CHAINING_PROVIDER_ELEMENT_NAME
public static final QName RELYING_PARTY_GROUP_ELEMENT_NAME
public static final QName TRUST_ENGINE_ELEMENT_NAME
private final org.slf4j.Logger log
private boolean isPresentNotChaining(@Nonnull Element element, @Nonnull String attribute)
element - the elementattribute - the attributeprivate boolean isTopMost(@Nonnull Element element)
RelyingPartyMetadataProvider.element - the element.protected abstract Class<? extends MetadataResolver> getNativeBeanClass(Element element)
AbstractSingleBeanDefinitionParser.getBeanClass(Element) but it may need to be shimmed in
AbstractMetadataProviderParser which may need to insert an extra bean.element - the Element that is being parsedClass of the bean that is being defined via parsing the supplied Element, or
null if noneAbstractSingleBeanDefinitionParser.getBeanClassName(org.w3c.dom.Element)protected final Class<? extends MetadataResolver> getBeanClass(Element element)
getBeanClass in class org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParserprotected final void doParse(Element element, org.springframework.beans.factory.xml.ParserContext parserContext, org.springframework.beans.factory.support.BeanDefinitionBuilder builder)
doParse in class org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParserprotected void doNativeParse(Element element, org.springframework.beans.factory.xml.ParserContext parserContext, org.springframework.beans.factory.support.BeanDefinitionBuilder builder)
AbstractSingleBeanDefinitionParser.doParse(Element, ParserContext, BeanDefinitionBuilder) but it may need
to be shimmed in this class which may need to insert an extra bean.element - the XML element being parsedparserContext - the object encapsulating the current state of the parsing processbuilder - used to define the BeanDefinitionAbstractSingleBeanDefinitionParser.doParse(Element, BeanDefinitionBuilder)private void processPredicateOptions(Element element, org.springframework.beans.factory.xml.ParserContext parserContext, org.springframework.beans.factory.support.BeanDefinitionBuilder builder)
element - the current element being processedparserContext - the current parser contextbuilder - the current bean definition builderCopyright © 1999–2018 Shibboleth Consortium. All rights reserved.