|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sap.conn.jco.server.JCoServerFactory
public abstract class JCoServerFactory
Factory for creating server instances used by JCo applications.
The factory uses the instance of ServerDataProvider
registered at the environment to get the server configuration properties. In each environment a suitable
implementation of the ServerDataProvider has to be registered to ensure an appropriate management
of server properties. The registration is performed with
com.sap.conn.jco.ext.Environment.registerServerDataProvider(ServerDataProvider)
.
Note: A server instance may become invalid if the server configuration
is changed or removed. In such cases the running operation will be finished, but further usage
of the invalidated server instance will be blocked by throwing a JCoException with the key
JCO_ERROR_SERVER_DATA_INVALID.
The application may fetch an updated server instance from the JCoServerFactory, if it is suitable for
the application scenario.
Method Summary | |
---|---|
static JCoServerFactory |
get()
Deprecated. Reserved for internal use - visibility might be reduced in future versions without further notice. Use the static methods instead. |
static int |
getNumberOfServerConnections(java.lang.String serverName)
Queries the number of server connections registered at the SAP gateway. |
abstract int |
getNumServerConnections(java.lang.String serverName)
Deprecated. Reserved for internal use - visibility might be reduced in future versions without further notice. Use getNumberOfServerConnections(String) instead. |
static JCoServer |
getServer(java.lang.String serverName)
Creates a new JCo server instance or returns the one which is already available. |
abstract JCoServer |
getServerInstance(java.lang.String serverName)
Deprecated. Reserved for internal use - visibility might be reduced in future versions without further notice. Use getServer(String) instead. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
@Deprecated public static JCoServerFactory get()
@Deprecated public abstract JCoServer getServerInstance(java.lang.String serverName) throws JCoException
getServer(String)
instead.
serverName
- the name of the server for which a JCoServer instance shall be returned
JCoException
- if the server configuration is wrong, e.g. a mandatory parameter is missing@Deprecated public abstract int getNumServerConnections(java.lang.String serverName) throws JCoException
getNumberOfServerConnections(String)
instead.
serverName
- the name of the server for which the number of registered server
connections shall be queried
JCoException
- if the gateway cannot be queriedpublic static JCoServer getServer(java.lang.String serverName) throws JCoException
serverName
- the name of the server for which we want to get a server instance
JCoException
- if the server configuration is wrong, e.g. a mandatory parameter is missingpublic static int getNumberOfServerConnections(java.lang.String serverName) throws JCoException
serverName
- the serverName for which the number of registered server
connections shall be queried
JCoException
- if the gateway cannot be queried
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |