Package org.opensaml.xmlsec.agreement

# Class KeyAgreementProcessorRegistry

java.lang.Object
org.opensaml.xmlsec.agreement.KeyAgreementProcessorRegistry

public class KeyAgreementProcessorRegistry extends Object
A component which provides access to registered instances of `KeyAgreementProcessor`.

## Field Summary

Fields
Modifier and Type
Field
Description
`private Map<String,KeyAgreementProcessor>`
`processors`
The registered processors.

## Constructor Summary

Constructors
Constructor
Description
`KeyAgreementProcessorRegistry()`
Constructor.

## Method Summary

Modifier and Type
Method
Description
`void`
`clear()`
Clear all registered processors.
`void`
`deregister(String algorithm)`
Deregister a processor.
`KeyAgreementProcessor`
`getProcessor(String algorithm)`
Get the processor registered for the specified algorithm.
`Set<String>`
`getRegisteredAlgorithms()`
Get the set of all registered algorithms.
`void`
`register(KeyAgreementProcessor processor)`
Register a processor.

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

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

## Field Details

### processors

@Nonnull private Map<String,KeyAgreementProcessor> processors
The registered processors.

## Constructor Details

### KeyAgreementProcessorRegistry

public KeyAgreementProcessorRegistry()
Constructor.

## Method Details

### register

public void register(@Nonnull KeyAgreementProcessor processor)
Register a processor.

Any existing processor registered for the given algorithm will be overwritten.

Parameters:
  `processor` - the processor to register

### deregister

public void deregister(@Nonnull String algorithm)
Deregister a processor.

Parameters:
  `algorithm` - the algorithm of the processor to deregister

### clear

public void clear()
Clear all registered processors.

### getRegisteredAlgorithms

@Nonnull @Unmodifiable @NotLive public Set<String> getRegisteredAlgorithms()
Get the set of all registered algorithms.

Returns:
  the set of registered algorithms

### getProcessor

@Nullable public KeyAgreementProcessor getProcessor(@Nonnull String algorithm)
Get the processor registered for the specified algorithm.

Parameters:
  `algorithm` - the processor algorithm
Returns:
  the processor registered for that algorithm