Class AttributeMappingNodeProcessor
java.lang.Object
net.shibboleth.idp.saml.metadata.impl.AttributeMappingNodeProcessor
- All Implemented Interfaces:
MetadataNodeProcessor
@NotThreadSafe
public class AttributeMappingNodeProcessor
extends Object
implements MetadataNodeProcessor
An implementation of
MetadataNodeProcessor
which extracts IdPRequestedAttribute
s from any
AttributeConsumingService
we find and IdPAttribute
s from any EntityDescriptor
that we find.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final AttributeTranscoder<Attribute>
Fallback for URI-named entity tags.private final org.slf4j.Logger
Class logger.private final ReloadableService<AttributeTranscoderRegistry>
Service used to get the registry of decoding rules. -
Constructor Summary
ConstructorsConstructorDescriptionConstructor. -
Method Summary
Modifier and TypeMethodDescriptionprivate <T> void
decodeAttribute
(Collection<TranscodingRule> rules, T input, Multimap<String, IdPAttribute> results) Access the registry of transcoding rules to decode the input object.private void
handleAttributeConsumingService
(AttributeTranscoderRegistry registry, AttributeConsumingService acs) Look inside theAttributeConsumingService
for anyRequestedAttribute
s and map them.private void
handleEntityAttributes
(AttributeTranscoderRegistry registry, Extensions extensions) Look inside theExtensions
forEntityAttributes
and map them.void
-
Field Details
-
log
@Nonnull private final org.slf4j.Logger logClass logger. -
transcoderRegistry
Service used to get the registry of decoding rules. -
defaultTranscoder
Fallback for URI-named entity tags.
-
-
Constructor Details
-
AttributeMappingNodeProcessor
public AttributeMappingNodeProcessor(@Nonnull ReloadableService<AttributeTranscoderRegistry> registry) Constructor.- Parameters:
registry
- the service for the decoding rules
-
-
Method Details
-
process
- Specified by:
process
in interfaceMetadataNodeProcessor
- Throws:
FilterException
-
handleAttributeConsumingService
private void handleAttributeConsumingService(@Nonnull AttributeTranscoderRegistry registry, @Nonnull AttributeConsumingService acs) Look inside theAttributeConsumingService
for anyRequestedAttribute
s and map them.- Parameters:
registry
- the registry serviceacs
- theAttributeConsumingService
to look at
-
handleEntityAttributes
private void handleEntityAttributes(@Nonnull AttributeTranscoderRegistry registry, @Nullable Extensions extensions) Look inside theExtensions
forEntityAttributes
and map them.- Parameters:
registry
- the registry serviceextensions
- the extensions block
-
decodeAttribute
private <T> void decodeAttribute(@Nonnull @NonnullElements Collection<TranscodingRule> rules, @Nonnull T input, @Nonnull @NonnullElements @Live Multimap<String, IdPAttribute> results) throws AttributeDecodingExceptionAccess the registry of transcoding rules to decode the input object.- Type Parameters:
T
- input type- Parameters:
rules
- transcoding rulesinput
- input objectresults
- collection to add results to- Throws:
AttributeDecodingException
- if an error occurs or no results were obtained
-