public void start ( BundleContext context ) throws Exception { ClassServiceUtility . log ( context , LogService . LOG_INFO , "Starting " + this . getClass ( ) . getName ( ) + " Bundle" ) ; this . context = context ; this . init ( ) ; // Setup the properties String interfaceClassName = getInterfaceClassName ( ) ; this . setProperty ( BundleConstants . ACTIVATOR , this . getClass ( ) . getName ( ) ) ; // In case I have to find this service by activator class try { context . addServiceListener ( this , ClassServiceUtility . addToFilter ( ( String ) null , Constants . OBJECTCLASS , interfaceClassName ) ) ; } catch ( InvalidSyntaxException e ) { e . printStackTrace ( ) ; } if ( service == null ) { boolean allStarted = this . checkDependentServices ( context ) ; if ( allStarted ) { service = this . startupService ( context ) ; this . registerService ( service ) ; } } }
Bundle starting up . Don t override this override startupService .