/** * Adds the specified ClientService and initializes it. If the service manager * has already been started then the service will also be started. */ public void addService( ClientService s ) { super.addService(s); }
/** * Retrieves the first sibling service of the specified * type. */ protected <T extends Service<S>> T getService( Class<T> type ) { return type.cast(serviceManager.getService(type)); }
/** * Removes the specified ClientService from this service manager, stopping * and terminating it as required. If this service manager is in a * started state then the service will be stopped. After removal, * the service will be terminated. */ public void removeService( ClientService s ) { super.removeService(s); } }
/** * Adds the specified service and initializes it. If the service manager * has already been started then the service will also be started. */ public <S extends Service<T>> void addService( S s ) { if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "addService({0})", s); } services.add(s); if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "Initializing service:{0}", s); } s.initialize(getParent()); if( started ) { if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "Starting service:{0}", s); } s.start(); } }
/** * Removes the specified HostedService from this service manager, stopping * and terminating it as required. If this service manager is in a * started state then the service will be stopped. After removal, * the service will be terminated. */ public void removeService( HostedService s ) { super.removeService(s); }
/** * Removes the specified service from this service manager, stopping * and terminating it as required. If this service manager is in a * started state then the service will be stopped. After removal, * the service will be terminated. */ public <S extends Service<T>> void removeService( S s ) { if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "removeService({0})", s); } if( started ) { if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "Stopping service:{0}", s); } s.stop(); } services.remove(s); if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "Terminating service:{0}", s); } s.terminate(getParent()); }
/** * Adds all of the specified ClientServices and initializes them. If the service manager * has already been started then the services will also be started. * This is a convenience method that delegates to addService(), thus each * service will be initialized (and possibly started) in sequence rather * than doing them all at the end. */ public void addServices( ClientService... services ) { for( ClientService s : services ) { super.addService(s); } }
/** * Removes the specified ClientService from this service manager, stopping * and terminating it as required. If this service manager is in a * started state then the service will be stopped. After removal, * the service will be terminated. */ public void removeService( ClientService s ) { super.removeService(s); } }
/** * Adds the specified service and initializes it. If the service manager * has already been started then the service will also be started. */ public <S extends Service<T>> void addService( S s ) { if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "addService({0})", s); } services.add(s); if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "Initializing service:{0}", s); } s.initialize(getParent()); if( started ) { if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "Starting service:{0}", s); } s.start(); } }
/** * Retrieves the first sibling service of the specified * type. */ protected <T extends Service<S>> T getService( Class<T> type ) { return type.cast(serviceManager.getService(type)); }
/** * Adds all of the specified HostedServices and initializes them. If the service manager * has already been started then the services will also be started. * This is a convenience method that delegates to addService(), thus each * service will be initialized (and possibly started) in sequence rather * than doing them all at the end. */ public void addServices( HostedService... services ) { for( HostedService s : services ) { super.addService(s); } }
/** * Removes the specified HostedService from this service manager, stopping * and terminating it as required. If this service manager is in a * started state then the service will be stopped. After removal, * the service will be terminated. */ public void removeService( HostedService s ) { super.removeService(s); }
/** * Removes the specified service from this service manager, stopping * and terminating it as required. If this service manager is in a * started state then the service will be stopped. After removal, * the service will be terminated. */ public <S extends Service<T>> void removeService( S s ) { if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "removeService({0})", s); } if( started ) { if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "Stopping service:{0}", s); } s.stop(); } services.remove(s); if( log.isLoggable(Level.FINE) ) { log.log(Level.FINE, "Terminating service:{0}", s); } s.terminate(getParent()); }
/** * Adds the specified HostedService and initializes it. If the service manager * has already been started then the service will also be started. */ public void addService( HostedService s ) { super.addService(s); }
/** * Adds the specified ClientService and initializes it. If the service manager * has already been started then the service will also be started. */ public void addService( ClientService s ) { super.addService(s); }
/** * Adds all of the specified HostedServices and initializes them. If the service manager * has already been started then the services will also be started. * This is a convenience method that delegates to addService(), thus each * service will be initialized (and possibly started) in sequence rather * than doing them all at the end. */ public void addServices( HostedService... services ) { for( HostedService s : services ) { super.addService(s); } }
/** * Adds all of the specified ClientServices and initializes them. If the service manager * has already been started then the services will also be started. * This is a convenience method that delegates to addService(), thus each * service will be initialized (and possibly started) in sequence rather * than doing them all at the end. */ public void addServices( ClientService... services ) { for( ClientService s : services ) { super.addService(s); } }
/** * Adds the specified HostedService and initializes it. If the service manager * has already been started then the service will also be started. */ public void addService( HostedService s ) { super.addService(s); }