|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectfr.cnes.sitools.tasks.business.Task
public final class Task
Task class aims at execute the API servers requests; retrieve the results; treat them to create a file or other; notify the end of the job. It also aims at put all operations details in a log file for future investigations by the user.
Constructor Summary | |
---|---|
Task(org.restlet.Context context,
org.restlet.Request r,
org.restlet.Response response,
java.lang.String id,
ResourceModel resourceModel,
org.restlet.security.User user,
java.util.logging.Level loggerLvl)
The Task constuctor |
|
Task(TaskModel taskModel)
Constructor Used for Task recovery at starting |
Method Summary | |
---|---|
org.restlet.Context |
getContext()
Gets the context value |
java.lang.String |
getCustomStatus()
Gets the customStatus value |
java.util.Date |
getEndDate()
Gets the endDate value |
java.util.logging.Logger |
getLogger()
Gets the logger value |
java.lang.String |
getMediaResult()
Gets the mediaResult value |
org.restlet.Request |
getRequest()
Get the request |
ResourceModel |
getResourceModel()
Gets the resourceModel value |
org.restlet.Response |
getResponse()
Gets the response value |
org.restlet.representation.Representation |
getResult()
Get the result of the treatment |
java.lang.String |
getRootUrl()
Gets the rootUrl value |
TaskRunTypeAdministration |
getRunTypeAdministration()
Gets the runType value |
java.util.Date |
getStartDate()
Gets the startDate value |
org.restlet.data.Status |
getStatus()
Gets the status value |
java.lang.String |
getStatusUrl()
Gets the statusUrl value |
java.lang.String |
getTaskId()
Get the task Identifier |
TaskModel |
getTaskModel()
Gets the taskModel value |
TaskStatus |
getTaskStatus()
Gets the status value |
long |
getTimestamp()
Gets the time stamp value |
java.lang.String |
getUrlResult()
Gets the urlResult value |
org.restlet.security.User |
getUser()
Gets the user value |
java.lang.String |
getUserId()
Gets the user value |
boolean |
isPersist()
Gets the persist value |
void |
run()
|
void |
runSynchrone()
Synchronous run |
void |
setContext(org.restlet.Context context)
Sets the value of context |
void |
setCustomStatus(java.lang.String customStatus)
Sets the value of customStatus |
void |
setEndDate(java.util.Date endDate)
Sets the value of endDate |
void |
setLogger(java.util.logging.Logger logger)
Sets the value of logger |
void |
setMediaResult(java.lang.String mediaResult)
Sets the value of mediaResult |
void |
setPersist(boolean persist)
Sets the value of persist |
void |
setRequest(org.restlet.Request request)
Set the request |
void |
setResourceModel(ResourceModel resourceModel)
Sets the value of resourceModel |
void |
setResponse(org.restlet.Response response)
Sets the value of response |
void |
setResult(org.restlet.representation.Representation result)
Set the result of the treatment |
void |
setRootUrl(java.lang.String rootUrl)
Sets the value of rootUrl |
void |
setRunType(TaskRunTypeAdministration runType)
Sets the value of runType |
void |
setStartDate(java.util.Date startDate)
Sets the value of startDate |
void |
setStatus(org.restlet.data.Status status)
Sets the value of status |
void |
setStatusUrl(java.lang.String statusUrl)
Sets the value of statusUrl |
void |
setTaskId(java.lang.String id)
Set the task Identifier |
void |
setTaskModel(TaskModel taskModel)
Sets the value of taskModel |
void |
setTaskStatus(TaskStatus status)
Sets the value of status |
void |
setTimestamp(long timestamp)
Sets the value of time stamp |
void |
setUrlResult(java.lang.String urlResult)
Sets the value of urlResult |
void |
setUser(org.restlet.security.User user)
Sets the value of user |
void |
setUserId(java.lang.String userId)
Sets the value of user |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Task(org.restlet.Context context, org.restlet.Request r, org.restlet.Response response, java.lang.String id, ResourceModel resourceModel, org.restlet.security.User user, java.util.logging.Level loggerLvl)
context
- the Restlet Context of the Taskr
- the request objectresponse
- the response objectid
- the id of the TaskresourceModel
- the Resource modeluser
- the UserloggerLvl
- the level of the loggerpublic Task(TaskModel taskModel)
taskModel
- The TaskModel of the TaskMethod Detail |
---|
public void run()
run
in interface java.lang.Runnable
public void runSynchrone()
public void setCustomStatus(java.lang.String customStatus)
customStatus
- the customStatus to setpublic java.lang.String getCustomStatus()
public void setUrlResult(java.lang.String urlResult)
urlResult
- the urlResult to setpublic java.lang.String getUrlResult()
public void setMediaResult(java.lang.String mediaResult)
mediaResult
- the mediaResult to setpublic java.lang.String getMediaResult()
public void setStatusUrl(java.lang.String statusUrl)
statusUrl
- the statusUrl to setpublic java.lang.String getStatusUrl()
public java.lang.String getTaskId()
public void setTaskId(java.lang.String id)
id
- the identifierpublic org.restlet.Context getContext()
public void setContext(org.restlet.Context context)
context
- the context to setpublic void setRequest(org.restlet.Request request)
request
- the request to setpublic org.restlet.Request getRequest()
public org.restlet.Response getResponse()
public void setResponse(org.restlet.Response response)
response
- the response to setpublic void setResult(org.restlet.representation.Representation result)
result
- the result to setpublic org.restlet.representation.Representation getResult()
public TaskStatus getTaskStatus()
public void setTaskStatus(TaskStatus status)
status
- the status to setpublic void setUserId(java.lang.String userId)
userId
- the userId to setpublic java.lang.String getUserId()
public void setTimestamp(long timestamp)
timestamp
- the time stamp to setpublic long getTimestamp()
public void setRootUrl(java.lang.String rootUrl)
rootUrl
- the rootUrl to setpublic java.lang.String getRootUrl()
public void setUser(org.restlet.security.User user)
user
- the user to setpublic org.restlet.security.User getUser()
public java.util.Date getStartDate()
public void setStartDate(java.util.Date startDate)
startDate
- the startDate to setpublic java.util.Date getEndDate()
public void setEndDate(java.util.Date endDate)
endDate
- the endDate to setpublic void setLogger(java.util.logging.Logger logger)
logger
- the logger to setpublic java.util.logging.Logger getLogger()
public void setRunType(TaskRunTypeAdministration runType)
runType
- the runType to setpublic TaskRunTypeAdministration getRunTypeAdministration()
public void setPersist(boolean persist)
persist
- the persist to setpublic boolean isPersist()
public TaskModel getTaskModel()
public void setTaskModel(TaskModel taskModel)
taskModel
- the taskModel to setpublic ResourceModel getResourceModel()
public void setResourceModel(ResourceModel resourceModel)
resourceModel
- the resourceModel to setpublic void setStatus(org.restlet.data.Status status)
status
- the status to setpublic org.restlet.data.Status getStatus()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |