jet.server.api
Interface ServerInfo

All Superinterfaces:
java.io.Serializable

public interface ServerInfo
extends java.io.Serializable

The ServerInfo interface provides some methods. JREngine can use these methods to get some information about the server and tasks. This interface will be provided to users, and users can develop their own codes by using it.


Method Summary
 java.util.Vector getParamDescs()
          Gets descriptions of all parameters used in the task.
 java.lang.String getRemoteAddress()
          Gets the address indicating client sent request.
 java.lang.String getRequestURL()
          Gets the requested URL.
 java.util.Properties getScheduleProperties()
          Gets task's schedule properties, e.g.
 java.util.Properties getTaskProperties()
          Gets task's properties, e.g.
 java.util.Vector getUserGroups(java.lang.String userID)
          Get all groups which contain the userID.
 

Method Detail

getTaskProperties

java.util.Properties getTaskProperties()
                                       throws RptServerException
Gets task's properties, e.g. task ID, task class and so on. If you want to transmit self-defined properties using the object of this class, you must name your properties with the prefix,APICont.TAG_USER_PROPS_PREFIX . For detailed information about the properties, please consult %installroot%\help\en\dialogs\admschd.htm.

Returns:
a Properties including the information.
Throws:
RptServerException

getScheduleProperties

java.util.Properties getScheduleProperties()
                                           throws RptServerException
Gets task's schedule properties, e.g. next run time, schedule type and so on. If this method returns null, it means that this task's launch type is instant launch, for detailed information about the properties, please consult %installroot%\help\en\dialogs\admschd.htm.

Returns:
a Properties including the information.
Throws:
RptServerException

getRequestURL

java.lang.String getRequestURL()
                               throws RptServerException
Gets the requested URL. If the task is a scheduled task, and JReport Server has been shut down after the schedule was submitted, the method will return null.

Returns:
a String indicated URL.
Throws:
RptServerException

getRemoteAddress

java.lang.String getRemoteAddress()
                                  throws RptServerException
Gets the address indicating client sent request. If the task is a scheduled task, and the server has been shut down after the schedule was submitted, the method will return null.

Returns:
a String indicated address.
Throws:
RptServerException

getUserGroups

java.util.Vector getUserGroups(java.lang.String userID)
                               throws RptServerException
Get all groups which contain the userID.

Parameters:
userID, - the user Id
Returns:
a Vector of user groups
Throws:
RptServerException

getParamDescs

java.util.Vector getParamDescs()
                               throws RptServerException
Gets descriptions of all parameters used in the task.

Returns:
a Vector, each element is a jet.formula.ParamDesc object. If no parameter is used in the task, a zero size Vector will be returned. After submitting the task, it contains user input value.
Throws:
RptServerException