org.apache.felix.metatype.internal
Class Activator
java.lang.Object
org.apache.felix.metatype.internal.Activator
- All Implemented Interfaces:
- BundleActivator
public class Activator
- extends Object
- implements BundleActivator
The Activator
class is the BundleActivator
of
this bundle and provides abstract logging functionality: If a
LogService
is available, that service is used, otherwise
logging goes to standard output or standard error (in case of level ERROR
messages).
- Author:
- fmeschbe
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Activator
public Activator()
start
public void start(BundleContext context)
- Starts this bundle doing the following:
- Register as listener for service events concerning the
LogService
- Try to get the
LogService
- Registers the
MetaTypeService
implementation provided
by this bundle.
- Specified by:
start
in interface BundleActivator
- Parameters:
context
- The BundleContext
of this activator's bundle
stop
public void stop(BundleContext context)
- Stops this bundle by just unregistering as a service listener.
The framework will take care of ungetting the LogService
and
unregistering the MetaTypeService
registered by the
start(BundleContext)
method.
- Specified by:
stop
in interface BundleActivator
- Parameters:
context
- The BundleContext
of this activator's bundle
log
public static void log(int level,
String message)
log
public static void log(int level,
String message,
Throwable exception)
log
public static void log(ServiceReference sr,
int level,
String message)
log
public static void log(ServiceReference sr,
int level,
String message,
Throwable exception)
Copyright © 2011 Apache Software Foundation. All Rights Reserved.