2 * Copyright (c) 2016 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.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.elanservice.impl.rev150216;
10 import org.opendaylight.vpnservice.elan.internal.ElanServiceProvider;
11 import org.opendaylight.controller.sal.binding.api.RpcProviderRegistry;
12 import org.opendaylight.yang.gen.v1.urn.opendaylight.vpnservice.idmanager.rev150403.IdManagerService;
13 import org.opendaylight.yang.gen.v1.urn.opendaylight.vpnservice.interfacemgr.rpcs.rev151003.OdlInterfaceRpcService;
14 import org.opendaylight.yang.gen.v1.urn.opendaylight.vpnservice.itm.rpcs.rev151217.ItmRpcService;
16 public class ElanServiceImplModule extends org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.elanservice.impl.rev150216.AbstractElanServiceImplModule {
17 public ElanServiceImplModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) {
18 super(identifier, dependencyResolver);
21 public ElanServiceImplModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.elanservice.impl.rev150216.ElanServiceImplModule oldModule, java.lang.AutoCloseable oldInstance) {
22 super(identifier, dependencyResolver, oldModule, oldInstance);
26 public void customValidation() {
27 // add custom validation form module attributes here.
31 public java.lang.AutoCloseable createInstance() {
32 RpcProviderRegistry rpcregistryDependency = getRpcregistryDependency();
33 IdManagerService idManager = rpcregistryDependency.getRpcService(IdManagerService.class);
34 ElanServiceProvider provider = new ElanServiceProvider(rpcregistryDependency);
35 provider.setNotificationService(getNotificationServiceDependency());
36 provider.setMdsalManager(getMdsalutilDependency());
37 provider.setInterfaceManager(getOdlinterfaceDependency());
38 provider.setInterfaceManagerRpcService(rpcregistryDependency.getRpcService(OdlInterfaceRpcService.class));
39 provider.setItmRpcService(rpcregistryDependency.getRpcService(ItmRpcService.class));
40 provider.setItmManager(getItmmanagerDependency());
41 provider.setIdManager(idManager);
42 provider.setEntityOwnershipService(getEntityOwnershipServiceDependency());
43 getBrokerDependency().registerProvider(provider);