HPSearch

cgl.hpsearch.wsproxy
Class InvocationContainer

java.lang.Object
  extended bycgl.hpsearch.wsproxy.InvocationContainer

public class InvocationContainer
extends Object

Invocation Container for the ProxyWebService

Author:
Harshawardhan S. Gadgil $Date: 2005/11/03 21:28:44 $

Constructor Summary
InvocationContainer()
           
 
Method Summary
 String getNewTemporaryFileName()
           
 String getProperty(String name)
          Returns the value of the property
 int init(ServiceSpecification ss)
          Creates an instance of a service specified by serviceName.
 String[] listServiceExceptions()
           
 String[] LoadContext(String contextID)
           
 void notifyClient(String msg)
          Handles the error raised by a service during execution.
 void registerTemporaryFile(String tmpFileName)
           
 void registerTiming(String description, double time)
           
 int resume()
          Resumes the service
 void serviceComplete(String completionStatus)
          Handler funtion for handling proper closing of all streams signifying process completion
 String serviceStatus()
          Returns the service status.
 void setLogEntry(String entry)
           
 void setProperty(String name, String value)
          Sets the service's system property
 int start()
          Starts a previously initialized service.
 String StoreContext(String contextID, String[] data)
           
 int suspend()
          Suspends the service
 int terminate()
          Terminates the service.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InvocationContainer

public InvocationContainer()
Method Detail

init

public int init(ServiceSpecification ss)
Creates an instance of a service specified by serviceName. On successful completion returns a INIT_SUCCESS else returns INIT_FAILURE.
A service can be specifed by its complete class name.For e.g. cgl.service.samples.DoNothingService

Parameters:
ss -
Returns:
- RunnableProxyWebService status.

listServiceExceptions

public String[] listServiceExceptions()
Returns:
List of exceptions thrown by this service

setProperty

public void setProperty(String name,
                        String value)
Sets the service's system property

Parameters:
name - Name of the property
value - Value to be set

getProperty

public String getProperty(String name)
Returns the value of the property

Parameters:
name - The property being queried
Returns:
The value of the property specified by name

serviceStatus

public String serviceStatus()
Returns the service status.
Recommended to run this after every start/stop/suspend/resume call.

Returns:
- Status

start

public int start()
Starts a previously initialized service. Will return an error if the service is not initialized


terminate

public int terminate()
Terminates the service. Typically no restart should be possible here.
Refer to suspend / restart functions for restartablilty


suspend

public int suspend()
Suspends the service


resume

public int resume()
Resumes the service


notifyClient

public void notifyClient(String msg)
Handles the error raised by a service during execution.

Parameters:
msg - - Convey the error to the error stream

serviceComplete

public void serviceComplete(String completionStatus)
Handler funtion for handling proper closing of all streams signifying process completion

Parameters:
completionStatus - - optional message to be sent to the corresponding WSProxyHandler about the service completion status.

registerTiming

public void registerTiming(String description,
                           double time)

getNewTemporaryFileName

public String getNewTemporaryFileName()

registerTemporaryFile

public void registerTemporaryFile(String tmpFileName)

setLogEntry

public void setLogEntry(String entry)

StoreContext

public String StoreContext(String contextID,
                           String[] data)

LoadContext

public String[] LoadContext(String contextID)

HPSearch

For comments and suggestions please send e-mail to Harshawardhan Gadgil
Last updated: June 9 2006