## org.eclipse.datatools.connectivity
Class ProfileConnectionManager

    java.lang.Object
      org.eclipse.datatools.connectivity.ProfileConnectionManager

public class ProfileConnectionManager
extends java.lang.Object

NON-API A simple reference count based connection pool. This class manages the life cycle of connections by handling `ConnectEvent`s through a registered `IConnectListener`. Connections are only managed for those profiles and connection factories registered with the manager by a client (i.e. if no client has registered with the connection manager, no connections are made).

Author:
  brianf, rcernich

Constructor Summary
`ProfileConnectionManager()`

Method Summary
`IConnection` `getConnection(IConnectionProfile profile, java.lang.String factoryID)`
`static ProfileConnectionManager` `getProfileConnectionManagerInstance()`
`void` `manageProfileConnection(IConnectionProfile profile, java.lang.String factoryID, java.lang.Object client)` If the client is an instance of IConnectListener, it will be notified of changes to the connect status of the profile.
`void` `unmanageProfileConnection(IConnectionProfile profile, java.lang.String factoryID, java.lang.Object client)`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ProfileConnectionManager

    public ProfileConnectionManager()

Method Detail

### getProfileConnectionManagerInstance

    public static ProfileConnectionManager getProfileConnectionManagerInstance()

### manageProfileConnection

    public void manageProfileConnection(IConnectionProfile profile,
                                        java.lang.String factoryID,
                                        java.lang.Object client)

  If the client is an instance of IConnectListener, it will be notified of changes to the connect status of the profile. The manager will notify each client after it has processed the event itself (i.e. the client will be notified after the connection has been opened or closed). For the okToClose event, each client is notified until one client returns false. At that point, no other clients are notified of the attempt to close.

  Parameters:
    `profile` -
    `factoryID` -
    `client` -

### unmanageProfileConnection

    public void unmanageProfileConnection(IConnectionProfile profile,
                                          java.lang.String factoryID,
                                          java.lang.Object client)

### getConnection

    public IConnection getConnection(IConnectionProfile profile,
                                     java.lang.String factoryID)

Copyright © 2006 Actuate, IBM Corporation, Sybase, Inc. and others. All rights reserved.