2 * Copyright (c) 2017 AT&T Intellectual Property. 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.bgpcep.pcep.topology.provider;
10 import static java.util.Objects.requireNonNull;
12 import java.net.InetSocketAddress;
13 import org.eclipse.jdt.annotation.NonNull;
14 import org.opendaylight.protocol.concepts.KeyMapping;
15 import org.opendaylight.protocol.pcep.PCEPDispatcherDependencies;
16 import org.opendaylight.protocol.pcep.PCEPPeerProposal;
17 import org.opendaylight.protocol.pcep.PCEPSessionListenerFactory;
19 final class PCEPDispatcherDependenciesImpl implements PCEPDispatcherDependencies {
20 private final @NonNull PCEPSessionListenerFactory listenerFactory;
21 private final @NonNull PCEPPeerProposal peerProposal;
23 private final @NonNull PCEPTopologyConfiguration topologyConfig;
25 PCEPDispatcherDependenciesImpl(final PCEPSessionListenerFactory listenerFactory,
26 final PCEPPeerProposal peerProposal, final PCEPTopologyConfiguration topologyConfig) {
27 this.listenerFactory = requireNonNull(listenerFactory);
28 this.peerProposal = requireNonNull(peerProposal);
29 this.topologyConfig = requireNonNull(topologyConfig);
33 public PCEPSessionListenerFactory getListenerFactory() {
34 return listenerFactory;
38 public PCEPPeerProposal getPeerProposal() {
43 public InetSocketAddress getAddress() {
44 return topologyConfig.getAddress();
48 public KeyMapping getKeys() {
49 return topologyConfig.getKeys();