***  This interface provides Binary Compatibility only, not Source Compatibility  ***

com.sas.services.connection.platform
Interface PlatformConnectionFactoryInterface

All Superinterfaces:
ConnectionFactoryInterface, ConnectionFactoryShellInterface

public interface PlatformConnectionFactoryInterface
extends ConnectionFactoryInterface

A specialization of the user interface for connection factories. This interface allows users to obtain connections from a connection factory using the Foundation User Service to identity the user requesting the connection.


Method Summary
 ConnectionInterface getConnection(UserContextInterface userContext)
          Get a connection to a server.
 ConnectionInterface getConnection(UserContextInterface userContext, long waitMilliseconds)
          Get a connection to a server.
 
Methods inherited from interface com.sas.services.connection.ConnectionFactoryInterface
getAdminInterface, getAdminInterface, getConnection, getConnection, getConnection, getConnection, getConnection, getConnection, getConnection, getConnection
 
Methods inherited from interface com.sas.services.connection.ConnectionFactoryShellInterface
addConnectionFactoryEventListener, getAdminInterface, getConnection, getConnection, getDomains, removeConnectionFactoryEventListener
 

Method Detail

getConnection

ConnectionInterface getConnection(UserContextInterface userContext)
                                  throws ConnectionFactoryException
Get a connection to a server. If the factory has allocated all the connections it is allowed to manage to users when this call is made, then this call will block until another user returns a connection to the factory's pool.

Parameters:
userContext - the context of someone allowed to use this factory
Returns:
a connection
Throws:
ConnectionFactoryException - if the factory cannot create a connection to satisfy this request or if the factory has been shutdown

getConnection

ConnectionInterface getConnection(UserContextInterface userContext,
                                  long waitMilliseconds)
                                  throws ConnectionFactoryException
Get a connection to a server. If the factory has allocated all the connections it is allowed to manage to users when this call is made, then this call will behave as instructed by the value of waitMilliseconds.

Parameters:
userContext - the context of someone allowed to use this factory
waitMilliseconds - a flag indicating how the call should behave if the factory has allocated all the connections it is allowed to manage to other users.

<0
throw an exception immediately
0
wait until another user returns a connection to the factory's pool
>0
wait up to waitMilliseconds milliseconds for another user to return a connection to the factory's pool and throw an exception if a connection is not returned in the alloted time
Returns:
a connection
Throws:
ConnectionFactoryException - if the factory cannot create a connection to satisfy this request or if the request times out or if the factory has been shutdown

***  This interface provides Binary Compatibility only, not Source Compatibility  ***




Copyright © 2009 SAS Institute Inc. All Rights Reserved.