JBoss Modular Service Kernel API 1.0.0.Beta1

org.jboss.msc.service
Class AbstractServiceListener<S>

java.lang.Object
  extended by org.jboss.msc.service.AbstractServiceListener<S>
All Implemented Interfaces:
ServiceListener<S>
Direct Known Subclasses:
RemovingServiceListener, TimingServiceListener

public abstract class AbstractServiceListener<S>
extends Object
implements ServiceListener<S>

An abstract implementation of a service listener whose methods do nothing.

Author:
David M. Lloyd

Constructor Summary
AbstractServiceListener()
           
 
Method Summary
 void listenerAdded(ServiceController<? extends S> controller)
          The listener has been added to a controller.
 void serviceFailed(ServiceController<? extends S> controller, StartException reason)
          The service start has failed.
 void serviceRemoved(ServiceController<? extends S> controller)
          The service has been removed.
 void serviceStarted(ServiceController<? extends S> controller)
          The service is started (up).
 void serviceStarting(ServiceController<? extends S> controller)
          The service is starting.
 void serviceStopped(ServiceController<? extends S> controller)
          The service is stopped (down).
 void serviceStopping(ServiceController<? extends S> controller)
          The service is stopping.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractServiceListener

public AbstractServiceListener()
Method Detail

listenerAdded

public void listenerAdded(ServiceController<? extends S> controller)
The listener has been added to a controller.

Specified by:
listenerAdded in interface ServiceListener<S>
Parameters:
controller - the controller that this listener was added to

serviceStarting

public void serviceStarting(ServiceController<? extends S> controller)
The service is starting. Called after the state transitions from DOWN to STARTING.

Specified by:
serviceStarting in interface ServiceListener<S>
Parameters:
controller - the controller

serviceStarted

public void serviceStarted(ServiceController<? extends S> controller)
The service is started (up). Called after the state transitions from STARTING to UP.

Specified by:
serviceStarted in interface ServiceListener<S>
Parameters:
controller - the controller

serviceFailed

public void serviceFailed(ServiceController<? extends S> controller,
                          StartException reason)
The service start has failed. Called after the state transitions from STARTING to START_FAILED.

Specified by:
serviceFailed in interface ServiceListener<S>
Parameters:
controller - the controller
reason - the reason for failure

serviceStopping

public void serviceStopping(ServiceController<? extends S> controller)
The service is stopping. Called after the state transitions from UP to STOPPING.

Specified by:
serviceStopping in interface ServiceListener<S>
Parameters:
controller - the controller

serviceStopped

public void serviceStopped(ServiceController<? extends S> controller)
The service is stopped (down). Called after the state transitions from STOPPING to DOWN.

Specified by:
serviceStopped in interface ServiceListener<S>
Parameters:
controller - the controller

serviceRemoved

public void serviceRemoved(ServiceController<? extends S> controller)
The service has been removed. The listener will automatically be unregistered after this call. Called after the state transitions from DOWN to REMOVED.

Specified by:
serviceRemoved in interface ServiceListener<S>
Parameters:
controller - the controller

JBoss Modular Service Kernel API 1.0.0.Beta1

Copyright © 2010 JBoss, a division of Red Hat, Inc.