Jitsi: the OpenSource Java VoIP and Instant Messaging client.

net.java.sip.communicator.plugin.reconnectplugin
Class ReconnectPluginActivator

java.lang.Object
  extended by net.java.sip.communicator.plugin.reconnectplugin.ReconnectPluginActivator
All Implemented Interfaces:
EventListener, NetworkConfigurationChangeListener, RegistrationStateChangeListener, org.osgi.framework.BundleActivator, org.osgi.framework.ServiceListener

public class ReconnectPluginActivator
extends Object
implements org.osgi.framework.BundleActivator, org.osgi.framework.ServiceListener, NetworkConfigurationChangeListener, RegistrationStateChangeListener

Activates the reconnect plug-in.

Author:
Damian Minkov

Field Summary
static String ATLEAST_ONE_CONNECTION_PROP
           
static String NETWORK_NOTIFICATIONS
          Network notifications event type.
 
Constructor Summary
ReconnectPluginActivator()
           
 
Method Summary
 void configurationChanged(ChangeEvent event)
          Fired when a change has occurred in the computer network configuration.
static ConfigurationService getConfigurationService()
          Returns a reference to a ConfigurationService implementation currently registered in the bundle context or null if no such implementation was found.
static NotificationService getNotificationService()
          Returns the NotificationService obtained from the bundle context.
static ResourceManagementService getResources()
          Returns resource service.
static UIService getUIService()
          Returns the UIService obtained from the bundle context.
 void registrationStateChanged(RegistrationStateChangeEvent evt)
          The method is called by a ProtocolProviderService implementation whenever a change in the registration state of the corresponding provider had occurred.
 void serviceChanged(org.osgi.framework.ServiceEvent serviceEvent)
          When new protocol provider is registered we add needed listeners.
 void start(org.osgi.framework.BundleContext bundleContext)
          Starts this bundle.
 void stop(org.osgi.framework.BundleContext bundleContext)
          Stops this bundle.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NETWORK_NOTIFICATIONS

public static final String NETWORK_NOTIFICATIONS
Network notifications event type.

See Also:
Constant Field Values

ATLEAST_ONE_CONNECTION_PROP

public static final String ATLEAST_ONE_CONNECTION_PROP
See Also:
Constant Field Values
Constructor Detail

ReconnectPluginActivator

public ReconnectPluginActivator()
Method Detail

start

public void start(org.osgi.framework.BundleContext bundleContext)
           throws Exception
Starts this bundle.

Specified by:
start in interface org.osgi.framework.BundleActivator
Parameters:
bundleContext - the BundleContext in which this bundle is to be started
Throws:
Exception - if anything goes wrong while starting this bundle

stop

public void stop(org.osgi.framework.BundleContext bundleContext)
          throws Exception
Stops this bundle.

Specified by:
stop in interface org.osgi.framework.BundleActivator
Parameters:
bundleContext - the BundleContext in which this bundle is to be stopped
Throws:
Exception - if anything goes wrong while stopping this bundle

getUIService

public static UIService getUIService()
Returns the UIService obtained from the bundle context.

Returns:
the UIService obtained from the bundle context

getResources

public static ResourceManagementService getResources()
Returns resource service.

Returns:
the resource service.

getConfigurationService

public static ConfigurationService getConfigurationService()
Returns a reference to a ConfigurationService implementation currently registered in the bundle context or null if no such implementation was found.

Returns:
a currently valid implementation of the ConfigurationService.

getNotificationService

public static NotificationService getNotificationService()
Returns the NotificationService obtained from the bundle context.

Returns:
the NotificationService obtained from the bundle context

serviceChanged

public void serviceChanged(org.osgi.framework.ServiceEvent serviceEvent)
When new protocol provider is registered we add needed listeners.

Specified by:
serviceChanged in interface org.osgi.framework.ServiceListener
Parameters:
serviceEvent - ServiceEvent

configurationChanged

public void configurationChanged(ChangeEvent event)
Fired when a change has occurred in the computer network configuration.

Specified by:
configurationChanged in interface NetworkConfigurationChangeListener
Parameters:
event - the change event.

registrationStateChanged

public void registrationStateChanged(RegistrationStateChangeEvent evt)
The method is called by a ProtocolProviderService implementation whenever a change in the registration state of the corresponding provider had occurred.

Specified by:
registrationStateChanged in interface RegistrationStateChangeListener
Parameters:
evt - the event describing the status change.

Jitsi: the OpenSource Java VoIP and Instant Messaging client.

Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under LGPL license.