org.apache.felix.ipojo

## Interface InstanceStateListener

All Known Implementing Classes:
  ArchitectureHandler, HandlerManager, InstanceDescription, InstanceManager, PrimitiveInstanceDescription

    public interface InstanceStateListener

This class defines instance state listeners. An instance state listener is notified of instance state changes. It needs to be registered on the instance by invoking the (`ComponentInstance.addInstanceStateListener(InstanceStateListener)` method. Once registered, the listener can track instance state changes. Received states are:
`ComponentInstance.VALID`
`ComponentInstance.INVALID`
`ComponentInstance.STOPPED`
`ComponentInstance.DISPOSED`

Author:
  Felix Project Team

### Method Summary

All Methods Instance Methods Abstract Methods
`void` `stateChanged(ComponentInstance instance, int newState)` State change listener callback method.

### Method Detail

#### stateChanged

    void stateChanged(ComponentInstance instance,
                      int newState)

State change listener callback method. Every time that a monitored instance's state changes, this method is called with the instance and the new state.

Parameters:
  `instance` - the changing instance
  `newState` - the new instance state