X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fnorthbound%2Fbundlescanner%2Fimplementation%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fnorthbound%2Fbundlescanner%2Finternal%2FActivator.java;fp=opendaylight%2Fnorthbound%2Fbundlescanner%2Fimplementation%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fnorthbound%2Fbundlescanner%2Finternal%2FActivator.java;h=6b0718c7e2c1ffb463dfa921410344e249da1fca;hb=feeeee8105b8f8262154d6c7d994fdbdb7eda1e2;hp=0000000000000000000000000000000000000000;hpb=e89176e4777c3511a60e6507628dfcb5e7046e3c;p=controller.git diff --git a/opendaylight/northbound/bundlescanner/implementation/src/main/java/org/opendaylight/controller/northbound/bundlescanner/internal/Activator.java b/opendaylight/northbound/bundlescanner/implementation/src/main/java/org/opendaylight/controller/northbound/bundlescanner/internal/Activator.java new file mode 100644 index 0000000000..6b0718c7e2 --- /dev/null +++ b/opendaylight/northbound/bundlescanner/implementation/src/main/java/org/opendaylight/controller/northbound/bundlescanner/internal/Activator.java @@ -0,0 +1,42 @@ +/** + * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ + +package org.opendaylight.controller.northbound.bundlescanner.internal; + +import org.apache.felix.dm.Component; +import org.opendaylight.controller.northbound.bundlescanner.IBundleScanService; +import org.opendaylight.controller.sal.core.ComponentActivatorAbstractBase; + +/** + * The activator registers the BundleScanner. + */ +public class Activator extends ComponentActivatorAbstractBase { + + @Override + protected void init() { + } + + @Override + protected void destroy() { + } + + @Override + protected Object[] getGlobalImplementations() { + return new Object[] { BundleScanServiceImpl.class }; + } + + @Override + protected void configureGlobalInstance(Component c, Object imp) { + if (!imp.equals(BundleScanServiceImpl.class)) return; + // export service + c.setInterface( + new String[] { IBundleScanService.class.getName() }, + null); + } + +}