2 * Copyright (c) 2019 Ericsson India Global Services Pvt Ltd. 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.netvirt.elan.l2gw.utils;
10 import javax.inject.Inject;
11 import javax.inject.Singleton;
13 import org.opendaylight.infrautils.jobcoordinator.JobCoordinator;
14 import org.opendaylight.mdsal.binding.api.DataBroker;
15 import org.opendaylight.netvirt.elan.cache.ConfigMcastCache;
16 import org.opendaylight.netvirt.elan.cache.ElanInstanceCache;
17 import org.opendaylight.netvirt.elan.cache.ElanInstanceDpnsCache;
18 import org.opendaylight.netvirt.elan.cache.ElanInterfaceCache;
19 import org.opendaylight.netvirt.elan.utils.ElanClusterUtils;
20 import org.opendaylight.netvirt.elan.utils.Scheduler;
23 public class ElanRefUtil {
25 private final DataBroker dataBroker;
26 private final ElanClusterUtils elanClusterUtils;
27 private final Scheduler scheduler;
28 private final JobCoordinator jobCoordinator;
29 private final ElanInstanceCache elanInstanceCache;
30 private final ElanInstanceDpnsCache elanInstanceDpnsCache;
31 private final ElanInterfaceCache elanInterfaceCache;
32 private final ConfigMcastCache configMcastCache;
35 public ElanRefUtil(DataBroker dataBroker,
36 ElanClusterUtils elanClusterUtils,
37 ElanInstanceCache elanInstanceCache,
38 ElanInstanceDpnsCache elanInstanceDpnsCache,
39 ElanInterfaceCache elanInterfaceCache,
40 ConfigMcastCache configMcastCache,
41 JobCoordinator jobCoordinator,
42 Scheduler scheduler) {
43 this.dataBroker = dataBroker;
44 this.elanClusterUtils = elanClusterUtils;
45 this.elanInstanceCache = elanInstanceCache;
46 this.elanInstanceDpnsCache = elanInstanceDpnsCache;
47 this.elanInterfaceCache = elanInterfaceCache;
48 this.configMcastCache = configMcastCache;
49 this.jobCoordinator = jobCoordinator;
50 this.scheduler = scheduler;
53 public DataBroker getDataBroker() {
57 public ElanClusterUtils getElanClusterUtils() {
58 return elanClusterUtils;
61 public ElanInstanceCache getElanInstanceCache() {
62 return elanInstanceCache;
65 public ElanInstanceDpnsCache getElanInstanceDpnsCache() {
66 return elanInstanceDpnsCache;
69 public ElanInterfaceCache getElanInterfaceCache() {
70 return elanInterfaceCache;
73 public JobCoordinator getJobCoordinator() {
74 return jobCoordinator;
77 public Scheduler getScheduler() {
81 public ConfigMcastCache getConfigMcastCache() {
82 return configMcastCache;