Package org.opensaml.messaging.context.navigate

# Class ParentContextLookup<StartContext extends BaseContext,ParentContext extends BaseContext>

java.lang.Object
org.opensaml.messaging.context.navigate.ParentContextLookup<StartContext,ParentContext>

Type Parameters:
  `StartContext` - type of starting context
  `ParentContext` - type of the parent context

All Implemented Interfaces:
  `Function<StartContext,ParentContext>`, `ContextDataLookupFunction<StartContext,ParentContext>`

public class ParentContextLookup<StartContext extends BaseContext,ParentContext extends BaseContext> extends Object implements ContextDataLookupFunction<StartContext,ParentContext>
A `ContextDataLookupFunction` that gets the parent of a given context.

## Field Summary

Fields
Modifier and Type
Field
Description
`private final Class<ParentContext>`
`parentType`
Parent type.

## Constructor Summary

Constructors
Constructor
Description
`ParentContextLookup(Class<ParentContext> type)`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`ParentContext`
`apply(StartContext input)`

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

### parentType

@Nonnull private final Class<ParentContext extends BaseContext> parentType
Parent type.

## Constructor Details

### ParentContextLookup

public ParentContextLookup(@Nonnull @ParameterName(name="type") Class<ParentContext> type)
Constructor.

Parameters:
  `type` - parent context type to look up

## Method Details

### apply

@Nullable public ParentContext apply(@Nullable StartContext input)

Specified by:
  `apply` in interface `Function<StartContext extends BaseContext,ParentContext extends BaseContext>`