J2EE1.4 SDK

com.sun.appserv.management.client
Interface ConnectionSource

All Known Implementing Classes:
AppserverConnectionSource

public interface ConnectionSource

A source of an MBeanServerConnection.

See Also:
AppserverConnectionSource, MBeanServerConnectionConnectionSource, MBeanServerConnectionSource

Method Summary
 MBeanServerConnection getExistingMBeanServerConnection()
           
 javax.management.remote.JMXConnector getJMXConnector(boolean forceNew)
           
 MBeanServerConnection getMBeanServerConnection(boolean forceNew)
          Return a valid MBeanServerConnection, making a new connection if necessary, or returning an existing one if still valid.
 

Method Detail

getMBeanServerConnection

public MBeanServerConnection getMBeanServerConnection(boolean forceNew)
                                               throws java.io.IOException
Return a valid MBeanServerConnection, making a new connection if necessary, or returning an existing one if still valid. Some implementations may choose to not allow creation of a new connection (when 'forceNew' is specified).

Should not be called frequently, as the check for validity will make a remote call.

An implementation may choose to ignore the 'forceNew' parameter and always return the same connection.

Parameters:
forceNew - creates a new connection instead of reusing an existing one
Returns:
the connection, or null if a new one is not possible
Throws:
java.io.IOException

getExistingMBeanServerConnection

public MBeanServerConnection getExistingMBeanServerConnection()
Returns:
existing connection, valid or not, may be null

getJMXConnector

public javax.management.remote.JMXConnector getJMXConnector(boolean forceNew)
                                                     throws java.io.IOException
Returns:
a JMXConnector or null if not appropriate
Throws:
java.io.IOException

J2EE1.4 SDK

Submit a bug or feature

Copyright 2003 Sun Microsystems, Inc. All rights reserved.