Package org.opensaml.saml.saml2.profile.impl

# Class AddNameIDToSubjects.NameIDPolicyLookupFunction

java.lang.Object
org.opensaml.saml.saml2.profile.impl.AddNameIDToSubjects.NameIDPolicyLookupFunction

All Implemented Interfaces:
  `Function<ProfileRequestContext,SAMLObject>`

Enclosing class:
  AddNameIDToSubjects

public static class AddNameIDToSubjects.NameIDPolicyLookupFunction extends Object implements Function<ProfileRequestContext,SAMLObject>
Lookup function that returns the `NameIDPolicy` from an `AuthnRequest` message returned from a lookup function, by default the inbound message.

## Field Summary

Fields
Modifier and Type
Field
Description
`private Function<ProfileRequestContext,AuthnRequest>`
`requestLookupStrategy`
Strategy used to locate the `AuthnRequest` to operate on.

## Constructor Summary

Constructors
Constructor
Description
`NameIDPolicyLookupFunction()`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`SAMLObject`
`apply(ProfileRequestContext profileRequestContext)`
`void`
`setRequestLookupStrategy(Function<ProfileRequestContext,AuthnRequest> strategy)`
Set the strategy used to locate the `AuthnRequest` to examine.

### 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

### requestLookupStrategy

@Nonnull private Function<ProfileRequestContext,AuthnRequest> requestLookupStrategy
Strategy used to locate the `AuthnRequest` to operate on.

## Constructor Details

### NameIDPolicyLookupFunction

public NameIDPolicyLookupFunction()
Constructor.

## Method Details

### setRequestLookupStrategy

public void setRequestLookupStrategy(@Nonnull Function<ProfileRequestContext,AuthnRequest> strategy)
Set the strategy used to locate the `AuthnRequest` to examine.

Parameters:
  `strategy` - strategy used to locate the `AuthnRequest`

### apply

@Nullable public SAMLObject apply(@Nullable ProfileRequestContext profileRequestContext)

Specified by:
  `apply` in interface `Function<ProfileRequestContext,SAMLObject>`