2 * Copyright (c) 2016 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.protocol.bgp.parser.spi;
10 import org.eclipse.jdt.annotation.NonNull;
13 * Serve as an entry gate for providers of {@link PeerSpecificParserConstraint} services.
16 public interface PeerSpecificParserConstraintProvider extends PeerSpecificParserConstraint {
19 * Register new {@link PeerConstraint} service.
20 * @param classType Class type of the service to be added.
21 * @param peerConstraint Peer constraint service to be added.
22 * @return True if service was added, false if not (such service is already registered).
24 <T extends PeerConstraint> boolean addPeerConstraint(@NonNull Class<T> classType, @NonNull T peerConstraint);