Package hudson.model.queue
Class ScheduleResult
java.lang.Object
hudson.model.queue.ScheduleResult
- Direct Known Subclasses:
ScheduleResult.Created
,ScheduleResult.Existing
,ScheduleResult.Refused
- Since:
- 1.521
- Author:
- Kohsuke Kawaguchi
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
static final class
static final class
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic ScheduleResult.Created
static ScheduleResult.Existing
IfisCreated()
returns true, then this method returns the newly created item, which is always of the typeQueue.WaitingItem
.getItem()
UnlessisRefused()
is true, this method either returns the newly created item in the queue or the existing item that's already in the queue that matched the submitted task.final boolean
Opposite ofisRefused()
boolean
If true, thegetItem()
is newly created as a result ofQueue.schedule2(hudson.model.Queue.Task, int, java.util.List<hudson.model.Action>)
.boolean
The scheduling of the task was refused and the queue didn't change.static ScheduleResult.Refused
refused()
-
Constructor Details
-
ScheduleResult
public ScheduleResult()
-
-
Method Details
-
isCreated
public boolean isCreated()If true, thegetItem()
is newly created as a result ofQueue.schedule2(hudson.model.Queue.Task, int, java.util.List<hudson.model.Action>)
. -
isRefused
public boolean isRefused()The scheduling of the task was refused and the queue didn't change. If this method returns true,getItem()
will return null. -
getItem
UnlessisRefused()
is true, this method either returns the newly created item in the queue or the existing item that's already in the queue that matched the submitted task. -
getCreateItem
IfisCreated()
returns true, then this method returns the newly created item, which is always of the typeQueue.WaitingItem
. -
isAccepted
public final boolean isAccepted()Opposite ofisRefused()
-
created
-
existing
-
refused
-