2 * Copyright (c) 2015 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
9 package org.opendaylight.yang.gen.v1.config.aaa.authn.netconf.plugin.rev150715;
11 import com.google.common.base.Preconditions;
12 import org.opendaylight.aaa.odl.CredentialServiceAuthProvider;
13 import org.opendaylight.controller.config.api.DependencyResolver;
14 import org.opendaylight.controller.config.api.ModuleIdentifier;
15 import org.osgi.framework.BundleContext;
17 public class AuthProviderModule extends org.opendaylight.yang.gen.v1.config.aaa.authn.netconf.plugin.rev150715.AbstractAuthProviderModule {
19 private BundleContext bundleContext;
21 public AuthProviderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver) {
22 super(identifier, dependencyResolver);
25 public AuthProviderModule(org.opendaylight.controller.config.api.ModuleIdentifier identifier, org.opendaylight.controller.config.api.DependencyResolver dependencyResolver, org.opendaylight.yang.gen.v1.config.aaa.authn.netconf.plugin.rev150715.AuthProviderModule oldModule, AutoCloseable oldInstance) {
26 super(identifier, dependencyResolver, oldModule, oldInstance);
29 public AuthProviderModule(final ModuleIdentifier moduleIdentifier, final DependencyResolver dependencyResolver, final AuthProviderModule oldModule, final AutoCloseable oldInstance, final BundleContext bundleContext) {
30 this(moduleIdentifier, dependencyResolver, oldModule, oldInstance);
31 this.bundleContext = bundleContext;
34 public AuthProviderModule(final ModuleIdentifier moduleIdentifier, final DependencyResolver dependencyResolver, final BundleContext bundleContext) {
35 this(moduleIdentifier, dependencyResolver);
36 this.bundleContext = bundleContext;
40 public void customValidation() {
41 Preconditions.checkNotNull(bundleContext, "BundleContext was not properly set up");
45 public AutoCloseable createInstance() {
46 return new CredentialServiceAuthProvider(bundleContext);