Class JobStatus
java.lang.Object
com.polarion.platform.jobs.spi.service.JobStatus
- All Implemented Interfaces:
IJobMultiStatus,IJobStatus,Serializable
Implementation of
IJobMultiStatus.
For simplicity non-multi status is not provided.
- Author:
- Stepan Roh, Polarion Software
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.polarion.platform.jobs.IJobStatus
IJobStatus.JobStatusType -
Constructor Summary
ConstructorsConstructorDescriptionJobStatus(IJobStatus.JobStatusType type, IJob job, String message, Throwable error) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddNestedStatus(IJobStatus status) Add nested status.getError()Exception cause ofIJobStatus.JobStatusType.STATUS_TYPE_FAILED(may be omitted).getJob()Job.Status message.Return nestedIJobStatuses.getType()Status type.toString()
-
Constructor Details
-
JobStatus
Constructor.- Parameters:
type- status typejob- job (can benull)message- message (can benull)error- error (can benull)- Throws:
IllegalArgumentException- if type isnull
-
-
Method Details
-
getType
Description copied from interface:IJobStatusStatus type.- Specified by:
getTypein interfaceIJobStatus- Returns:
IJobStatus.JobStatusType(notnull)
-
getJob
Description copied from interface:IJobStatusJob.May return
nullif used post-mortem.- Specified by:
getJobin interfaceIJobStatus- Returns:
IJobornull
-
getMessage
Description copied from interface:IJobStatusStatus message.- Specified by:
getMessagein interfaceIJobStatus- Returns:
- message or
null
-
getError
Description copied from interface:IJobStatusException cause ofIJobStatus.JobStatusType.STATUS_TYPE_FAILED(may be omitted).- Specified by:
getErrorin interfaceIJobStatus- Returns:
- exception or
null
-
toString
-
addNestedStatus
Description copied from interface:IJobMultiStatusAdd nested status.- Specified by:
addNestedStatusin interfaceIJobMultiStatus- Parameters:
status- status to nest
-
getNestedStatuses
Description copied from interface:IJobMultiStatusReturn nestedIJobStatuses.- Specified by:
getNestedStatusesin interfaceIJobMultiStatus- Returns:
CollectionofIJobStatuses (notnull)
-