Class PeerSpecificParserConstraintImpl
java.lang.Object
org.opendaylight.protocol.bgp.parser.spi.pojo.PeerSpecificParserConstraintImpl
- All Implemented Interfaces:
PeerSpecificParserConstraint
,PeerSpecificParserConstraintProvider
public class PeerSpecificParserConstraintImpl
extends Object
implements PeerSpecificParserConstraintProvider
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription<T extends PeerConstraint>
booleanaddPeerConstraint
(Class<T> classType, T peerConstraint) Register newPeerConstraint
service.<T extends PeerConstraint>
Optional<T>getPeerConstraint
(Class<T> peerConstraintType) Looks-up and optionally returnsPeerConstraint
service.
-
Constructor Details
-
PeerSpecificParserConstraintImpl
public PeerSpecificParserConstraintImpl()
-
-
Method Details
-
getPeerConstraint
Description copied from interface:PeerSpecificParserConstraint
Looks-up and optionally returnsPeerConstraint
service.- Specified by:
getPeerConstraint
in interfacePeerSpecificParserConstraint
- Parameters:
peerConstraintType
- Class type of the service.- Returns:
- Optional of the required service, absent if the service is not available.
-
addPeerConstraint
Description copied from interface:PeerSpecificParserConstraintProvider
Register newPeerConstraint
service.- Specified by:
addPeerConstraint
in interfacePeerSpecificParserConstraintProvider
- Parameters:
classType
- Class type of the service to be added.peerConstraint
- Peer constraint service to be added.- Returns:
- True if service was added, false if not (such service is already registered).
-