Class SimpleExtension

  • All Implemented Interfaces:
    Extension

    public abstract class SimpleExtension
    extends java.lang.Object
    implements Extension
    • Constructor Summary

      Constructors 
      Constructor Description
      SimpleExtension​(org.osgi.framework.Bundle bundle)  
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      void destroy()
      Destroy should be synchronous and only return when the extension has been fully destroyed.
      protected abstract void doDestroy()  
      protected abstract void doStart()  
      protected java.lang.Object getLock()  
      boolean isDestroyed()  
      void start()
      Start this extension.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SimpleExtension

        public SimpleExtension​(org.osgi.framework.Bundle bundle)
    • Method Detail

      • isDestroyed

        public boolean isDestroyed()
      • start

        public void start()
                   throws java.lang.Exception
        Description copied from interface: Extension
        Start this extension. Starting and stopping of the extension should be synchronized.
        Specified by:
        start in interface Extension
        Throws:
        java.lang.Exception - If starting fails.
      • destroy

        public void destroy()
                     throws java.lang.Exception
        Description copied from interface: Extension
        Destroy should be synchronous and only return when the extension has been fully destroyed. In addition it must be synchronized with start, because start() and destroy() can be called concurrently.
        Specified by:
        destroy in interface Extension
        Throws:
        java.lang.Exception - If destroying fails.
      • getLock

        protected java.lang.Object getLock()
      • doStart

        protected abstract void doStart()
                                 throws java.lang.Exception
        Throws:
        java.lang.Exception
      • doDestroy

        protected abstract void doDestroy()
                                   throws java.lang.Exception
        Throws:
        java.lang.Exception