Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

Kapitel 3. Bundles > Der Bundle-Aktivator

3.4. Der Bundle-Aktivator

3.4.1. Das Interface BundleActivator

Mithilfe eines Bundle-Aktivators kann ein Bundle beim Start und beim Stopp beliebige Operationen ausführen. Der Bundle-Aktivator muss das Interface org.osgi.framework.BundleActivator implementieren. Dieses Interface definiert die vom Bundle-Entwickler zu implementierenden Methoden, die beim Start und beim Stopp eines Bundles vom Framework aufgerufen werden (vgl. Listing 3-3).

Listing 3-3. Das Interface BundleActivator

package org.osgi.framework;

  public interface BundleActivator {
     public void start(BundleContext context) throws Exception;
     public void stop(BundleContext context) throws Exception;
   }


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial