Reputation: 663
I am using Apache Felix dependency manager in my project. In the service activation method
@org.apache.felix.dm.annotation.api.Start
public void activate() {
// Need BundleContext here
}
I need an access to BundleContext or Bundle. How can I achieve this?
Upvotes: 2
Views: 199
Reputation: 413
You can make a volatile BundleContext field in your class and the dependency manager will inject it.
Upvotes: 1