com.sap.mw.jco
Interface IMiddleware.IServer

Enclosing class:
IMiddleware

public static interface IMiddleware.IServer

Middleware methods needed to implement a server


Method Summary
 void abort(JCO.Server server, java.lang.String message)
          Closes a connection and tries to send a final message to the caller
 void disconnect(JCO.Server server)
          Closes a connection
 void getAttributes(JCO.Server server)
          Method that actually retrieves the attributes of a connection.
 java.lang.String[][] getPropertyInfo()
          Returns information about the properties which are understood by the server implementation.
 void initialize(JCO.Server server, java.util.Properties params)
          Called to initialize the server just after its creation.
 boolean isAlive(JCO.Server client)
          Checks whether the connection is alive
 void listen(JCO.Server server, java.lang.String params)
          Listens for incoming calls and dispatches them to the servers handleRequestMethod()
 

Method Detail

getPropertyInfo

public java.lang.String[][] getPropertyInfo()
Returns information about the properties which are understood by the server implementation. Each element of the array should be a set of two Strings containg the name and description of a property. For example
  String pinfo[][] = {
     { "jco.server.gwhost",   "Gateway host"            },
     { "jco.server.gwserv",   "Gateway service"         },
     { "jco.server.progid",   "The servers' program id" },
  };
  

initialize

public void initialize(JCO.Server server,
                       java.util.Properties params)
Called to initialize the server just after its creation. This routine has to parse the properties and must set the conn_param field in the client.
Parameters:
server - the server that calls the method
params - connection parameters as a property list

listen

public void listen(JCO.Server server,
                   java.lang.String params)
Listens for incoming calls and dispatches them to the servers handleRequestMethod()
Parameters:
server - the server that calls the method
params - implementation dependent arguments which specify the connection

disconnect

public void disconnect(JCO.Server server)
Closes a connection
Parameters:
server - the server that calls the method

abort

public void abort(JCO.Server server,
                  java.lang.String message)
Closes a connection and tries to send a final message to the caller
Parameters:
server - the server that calls the method

isAlive

public boolean isAlive(JCO.Server client)
Checks whether the connection is alive
Parameters:
client - the client that calls the method
Returns:
true if the connection is alive, false otherwise

getAttributes

public void getAttributes(JCO.Server server)
Method that actually retrieves the attributes of a connection. An implementation has to set the attributes variable in the server object.
Parameters:
server - the server that calls the method