public class ScheduledDeadlineInfo extends Object implements Comparable<ScheduledDeadlineInfo>
Constructor and Description |
---|
ScheduledDeadlineInfo(Instant scheduleTime,
String deadlineName,
String scheduleId,
int counter,
DeadlineMessage<?> deadlineMessage,
ScopeDescriptor deadlineScope)
Instantiates a ScheduledDeadlineInfo.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(ScheduledDeadlineInfo other) |
DeadlineMessage<?> |
deadlineMessage()
|
boolean |
equals(Object o) |
int |
getCounter()
Retrieve the counter used to differentiate two deadlines scheduled at the same time.
|
String |
getDeadlineName()
Retrieve a
String denoting the name of the deadline; can be used together with the scheduleId to
cancel the deadline. |
ScopeDescriptor |
getDeadlineScope()
Retrieve a description of the
Scope in which the deadline is scheduled. |
String |
getScheduleId()
Retrieve a
String identifier representing the scheduled deadline; can be used together with the
deadlineName to cancel the deadline. |
Instant |
getScheduleTime()
Retrieve the time as an
Instant at which the deadline is scheduled. |
int |
hashCode() |
ScheduledDeadlineInfo |
recreateWithNewMessage(DeadlineMessage<?> deadlineMessage)
Creates a new instance of scheduled deadline info with new
deadlineMessage . |
public ScheduledDeadlineInfo(Instant scheduleTime, String deadlineName, String scheduleId, int counter, DeadlineMessage<?> deadlineMessage, ScopeDescriptor deadlineScope)
scheduleTime
- The time as an Instant
at which the deadline is scheduleddeadlineName
- A String
denoting the name of the deadline; can be used together with the
scheduleId
to cancel the deadlinescheduleId
- A String
identifier representing the scheduled deadline; can be used together
with the deadlineName
to cancel the deadlinecounter
- Used to differentiate two deadlines scheduled at the same timedeadlineMessage
- The deadline message of the scheduled deadline.deadlineScope
- A description of the Scope
in which the deadline is
scheduledpublic ScheduledDeadlineInfo recreateWithNewMessage(DeadlineMessage<?> deadlineMessage)
deadlineMessage
. Other fields are the
same.deadlineMessage
- New deadline messagedeadlineMessage
public Instant getScheduleTime()
Instant
at which the deadline is scheduled.Instant
at which the deadline is scheduledpublic String getDeadlineName()
String
denoting the name of the deadline; can be used together with the scheduleId
to
cancel the deadline.String
denoting the name of the deadline; can be used together with the scheduleId
to
cancel the deadlinepublic String getScheduleId()
String
identifier representing the scheduled deadline; can be used together with the
deadlineName
to cancel the deadline.String
identifier representing the scheduled deadline; can be used together with the
deadlineName
to cancel the deadlinepublic int getCounter()
public ScopeDescriptor getDeadlineScope()
Scope
in which the deadline is scheduled.Scope
in which the deadline is scheduledpublic DeadlineMessage<?> deadlineMessage()
DeadlineMessage
constructed out of the deadlineName
and deadlineInfo
public int compareTo(ScheduledDeadlineInfo other)
compareTo
in interface Comparable<ScheduledDeadlineInfo>
Copyright © 2010–2024. All rights reserved.