Functions Reference

There are two function types, One is about user maintenance and the other is for the schedule process. The functions include:

login

public LoginResult login( LoginInfo loginInfo)
Account and password are required to log on WebExronos system. After successful login, the service will return an identity string. This identity string will be used in the next operation.
Login is the first operation in the invoke chain. The identity string will be invalid after 20 minutes if the client doesn't send it back to the server in other operations.
Parameters
  loginInfo Include login account and password.
Return
  LoginResult Include return result. If login success, the identity string will be return.

modifyUser

public BasicResult modifyUser( UserInfo user, String sessionId)
Modify the user information. The user account information can be updated except the Account. Only the site admin can modify any account information. If not, he can only modify his information.
Parameters
  user Include the information that needs to be changed. All fields are required, and the account can not be changed.
  sessionId The identity string fetched in login operation.
Return
  BasicResult Operation result, include error information if server catch a error.

schedule

public ScheduleResult schedule( TimeSchedule schedule, CallBack callBack, String sessionId)
Create a schedule and store it in WebExronos server. The identity fetched in login operation is required in this function.
Parameters
  schedule Include the information that when WebExronos server calls back, the frequency and times that the server should call back, etc. base on this parameter's setting.
  callBack Include the information that how WebExronos server calls back. The method and parameters are required.
  sessionId The identity that fetched by login operation.
Return
  ScheduleResult Return result. If the server catches an error, the result includes the error information. If it's successful, it returns the job's name string.

cancelSchedule

public BasicResult cancelSchedule(String jobName, String sessionId)
Cancel a indicated job. The jobName parameter is fetched from the result of schedule function.
Parameters
  jobName The job name coming from the result of schedule function.
  sessionId The identity that fetched by login operation
Return
  BasicResult Operation result, include error information if server catch a error.

cancelAllSchedule

public BasicResult cancelAllSchedule(String sessionId)
Cancel all scheduled job belonging to this user.
Parameters
  sessionId The identity that fetched by login operation
Return
  BasicResult Operation result, include error information

modifySchedule

public ScheduleResult modifySchedule(String jobName, TimeSchedule schedule, CallBack callBack, String sessionId)
Modify a existed Schedule indicated by job name..
Parameters
  jobName The schedule name that to be modified.
  schedule Include the information that when WebExronos server calls back, the frequency and times that the server should call back, etc. base on this parameter's setting.
  callBack Include the information that how WebExronos server calls back. The method and parameters are required.
  sessionId The identity that fetched by login operation
Return
  ScheduleResult Operation result, include error information if server catch a error.