|
CodeBeamer 5.4.0.1-RC API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.intland.codebeamer.persistence.dto.base.IdentifiableDto
com.intland.codebeamer.persistence.dto.TrackerItemEscalationRuleDto
public class TrackerItemEscalationRuleDto
The definition of a tracker item escalation rule.
Nested Class Summary | |
---|---|
static class |
TrackerItemEscalationRuleDto.Anchor
The anchor defines how to compute the escalation firing date and time based on the specified time offset and the (Date) value/last modification date of the tracker item anchor field |
Nested classes/interfaces inherited from class com.intland.codebeamer.persistence.dto.base.IdentifiableDto |
---|
IdentifiableDto.IdComparator |
Field Summary | |
---|---|
static java.lang.Integer |
DAYS
|
static java.lang.Integer |
HOURS
|
static java.lang.Integer |
MINUTES
|
static int |
NOTIFY_ADDITIONAL_LISTENERS
Send escalation notifications to the named additional listeners |
static int |
NOTIFY_ISSUE_ASSIGNEES
Send escalation notifications to users assigned to the issue |
static int |
NOTIFY_ISSUE_SUBMITTER
Send escalation notifications to the issue submitter |
static int |
NOTIFY_ISSUE_SUPERVISORS
Send escalation notifications to users supervising the issue |
static java.lang.Integer |
SECONDS
TimeUnits for the offset calculation |
Constructor Summary | |
---|---|
TrackerItemEscalationRuleDto()
Create a default TrackerItemEscalationRuleDto |
|
TrackerItemEscalationRuleDto(java.lang.Integer trackerId,
NamedDto predicate,
int level)
Create a new TrackerItemEscalationRuleDto with the specified key attributes |
|
TrackerItemEscalationRuleDto(java.lang.Integer trackerId,
NamedDto predicate,
int level,
java.lang.String offset,
java.lang.Integer unit,
TrackerItemEscalationRuleDto.Anchor anchor,
java.lang.Integer fieldId,
java.lang.Integer statusId)
Create a new TrackerItemEscalationRuleDto with the specified attributes |
|
TrackerItemEscalationRuleDto(TrackerItemEscalationRuleDto base)
TrackerItemEscalationRuleDto copy constructor |
Method Summary | |
---|---|
int |
compareTo(java.lang.Object obj)
TrackerItemEscalationRuleDtos are compared by tracker id, predicate name and level |
boolean |
equals(java.lang.Object obj)
Two TrackerItemEscalationRuleDtos are equal, if their tracker id, predicate id and level are equal |
TrackerItemEscalationRuleDto.Anchor |
getAnchor()
Get the TrackerItemEscalationRuleDto.Anchor relation between the specified offset and the tracker item anchor field |
java.lang.Integer |
getAudience()
Get the target audience for notification mails emitted by this notification rule. |
TrackerItemCompiledExpression<java.lang.Number> |
getCompiledOffset()
Get the compiled script/formula to calculate the time offset |
java.lang.Integer |
getFieldId()
Get the ID of the escalation anchor field. |
java.lang.Integer |
getId()
Get the ID of the tracker, this escalation rule was declared at |
int |
getLevel()
Get the escalation level |
java.util.List<? extends NamedDto> |
getListeners()
Get the list of additional listeners (other than issue submitter/assignees/supervisors) for notifications emitted by this rule |
java.lang.String |
getOffset()
Get the formula to compute the time offset measured in unit, relative to the field according to anchor |
static long |
getOffset(java.lang.Number offset,
java.lang.Integer unit,
java.util.concurrent.TimeUnit inUnit)
Convert the specified offset into the specified result unit Note: Converting to/from days is with 24h/day, which is not appropriate for working time calculations! |
java.lang.Number |
getOffset(TrackerLayoutDto tracker,
TrackerItemDto item)
Compute the time offset of this rule for the specified item |
long |
getOffset(TrackerLayoutDto tracker,
TrackerItemDto item,
java.util.concurrent.TimeUnit inUnit)
Get the computed time offset of this rule for the specified item, relative to the anchor field, in the specified unit Note: Converting to/from days is with 24h/day, which is not appropriate for working time calculations! |
java.lang.Boolean |
getOnlyMembers()
Check if only direct project members in the specified role should be notified (true), or also indirect members (false) |
NamedDto |
getPredicate()
Get the tracker item filter/predicate, to determine which tracker items are subject of escalation |
java.lang.Integer |
getStatusId()
Get the ID of the escalation target status (if any). |
java.lang.Integer |
getUnit()
Get the time unit of the specified offset |
boolean |
isAudience(int bits)
Check if all of the specified bits are set in the audience mask |
void |
setAnchor(TrackerItemEscalationRuleDto.Anchor anchor)
Set how to compute the escalation firing date and time based on the specified offset and tracker item anchor field |
void |
setAudience(java.lang.Integer audience)
Set the target audience for notification mails emitted by this notification rule. |
void |
setCompiledOffset(TrackerItemCompiledExpression<java.lang.Number> compiledOffset)
Set the compiled script/formula to calculate the time offset |
void |
setFieldId(java.lang.Integer fieldId)
Set the ID of the anchor field for this escalation level. |
void |
setLevel(int level)
Set the escalation level |
void |
setListeners(java.util.List<? extends NamedDto> listeners)
Set the list of additional listeners (other than issue submitter/assignees/supervisors) for notifications emitted by this rule |
void |
setOffset(java.lang.String offset)
Set the formula to compute the time offset measured in unit, relative to the field according to anchor |
void |
setOnlyMembers(java.lang.Boolean onlyMembers)
Set whether only direct project members in the specified role should be notified (true), or also indirect members (false) |
void |
setPredicate(NamedDto predicate)
Set the tracker item filter/predicate, to determine which tracker items are subject of escalation |
void |
setStatusId(java.lang.Integer statusId)
Set the ID of the escalation target status (if any). |
void |
setUnit(java.lang.Integer unit)
Set the time unit of the specified offset, defaults to HOURS if null |
java.lang.String |
toString()
|
Methods inherited from class com.intland.codebeamer.persistence.dto.base.IdentifiableDto |
---|
clone, compare, compareInteger, equals, hashCode, hashCode, setId |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int NOTIFY_ISSUE_SUBMITTER
public static final int NOTIFY_ISSUE_ASSIGNEES
public static final int NOTIFY_ISSUE_SUPERVISORS
public static final int NOTIFY_ADDITIONAL_LISTENERS
public static final java.lang.Integer SECONDS
public static final java.lang.Integer MINUTES
public static final java.lang.Integer HOURS
public static final java.lang.Integer DAYS
Constructor Detail |
---|
public TrackerItemEscalationRuleDto()
public TrackerItemEscalationRuleDto(java.lang.Integer trackerId, NamedDto predicate, int level)
trackerId
- is the ID of the TrackerDto
the item escalation belongs tolevel
- is the escalation level number [1 ... n] (must be unique within tracker)predicate
- is the tracker item filter/predicate, to determine which tracker items are subject of escalationpublic TrackerItemEscalationRuleDto(java.lang.Integer trackerId, NamedDto predicate, int level, java.lang.String offset, java.lang.Integer unit, TrackerItemEscalationRuleDto.Anchor anchor, java.lang.Integer fieldId, java.lang.Integer statusId)
trackerId
- is the ID of the TrackerDto
the item escalation belongs tolevel
- is the escalation level number [1 ... n] (must be unique within tracker)predicate
- is the tracker item filter/predicate, to determine which tracker items are subject of escalationoffset
- is the formula to calculate the time offset in the specified unit, relative to the specified field according to anchorunit
- is the time unit of the specified offset, defaults to HOURS if nullanchor
- is the TrackerItemEscalationRuleDto.Anchor
that determines the relation between the specified offset and tracker item fieldfieldId
- is the ID of the anchor field of this escalation level. The escalation firing date and time is calculated relative to this field's value or last modification time, based on offset, unit and anchorstatusId
- is the ID of the new status for the target tracker item upon escalation, or null to not change the item statuspublic TrackerItemEscalationRuleDto(TrackerItemEscalationRuleDto base)
base
- escalation level to copyMethod Detail |
---|
public java.lang.Integer getId()
getId
in class IdentifiableDto
public NamedDto getPredicate()
public void setPredicate(NamedDto predicate)
predicate
- is the tracker item filter/predicate, to determine which tracker items are subject of escalationpublic int getLevel()
public void setLevel(int level)
level
- is the escalation level, that must be unique within a tracker and predicate/grouppublic java.lang.String getOffset()
public void setOffset(java.lang.String offset)
offset
- is the formula to compute the time offset in the specified unit, relative to the specified field according to anchorpublic TrackerItemCompiledExpression<java.lang.Number> getCompiledOffset()
public void setCompiledOffset(TrackerItemCompiledExpression<java.lang.Number> compiledOffset)
compiledOffset
- is the compiled script/formula to calculate the time offset, or nullpublic java.lang.Number getOffset(TrackerLayoutDto tracker, TrackerItemDto item)
item
- is the target item
public static long getOffset(java.lang.Number offset, java.lang.Integer unit, java.util.concurrent.TimeUnit inUnit)
offset
- to convertunit
- of the offset to convert, defaults to HOURS if nullinUnit
- to get the offset in, defaults to TimeUnit.SECONDS
if null
public long getOffset(TrackerLayoutDto tracker, TrackerItemDto item, java.util.concurrent.TimeUnit inUnit)
tracker
- is the target tracker layoutitem
- is the target iteminUnit
- to get the offset in, defaults to TimeUnit.SECONDS
if null
public java.lang.Integer getUnit()
public void setUnit(java.lang.Integer unit)
public TrackerItemEscalationRuleDto.Anchor getAnchor()
TrackerItemEscalationRuleDto.Anchor
relation between the specified offset and the tracker item anchor field
TrackerItemEscalationRuleDto.Anchor
relation between the specified offset and the tracker item anchor fieldpublic void setAnchor(TrackerItemEscalationRuleDto.Anchor anchor)
anchor
- is the TrackerItemEscalationRuleDto.Anchor
that determines the relation between the specified offset and tracker item fieldpublic java.lang.Integer getFieldId()
public void setFieldId(java.lang.Integer fieldId)
fieldId
- is the ID of the anchor field for this escalation levelpublic java.lang.Integer getStatusId()
public void setStatusId(java.lang.Integer statusId)
statusId
- is the ID of the new status for the target tracker item upon escalation, or null to not change the item statuspublic java.lang.Integer getAudience()
NOTIFY_ISSUE_SUBMITTER
NOTIFY_ISSUE_ASSIGNEES
NOTIFY_ISSUE_SUPERVISORS
NOTIFY_ADDITIONAL_LISTENERS
defined in getListeners()
public void setAudience(java.lang.Integer audience)
NOTIFY_ISSUE_SUBMITTER
NOTIFY_ISSUE_ASSIGNEES
NOTIFY_ISSUE_SUPERVISORS
NOTIFY_ADDITIONAL_LISTENERS
defined in getListeners()
audience
- is the target audience for notification mails emitted by this notification rule.public boolean isAudience(int bits)
public java.util.List<? extends NamedDto> getListeners()
public void setListeners(java.util.List<? extends NamedDto> listeners)
listeners
- is a list of additional listeners (users and/or roles) for notifications emitted by this rulepublic java.lang.Boolean getOnlyMembers()
public void setOnlyMembers(java.lang.Boolean onlyMembers)
onlyMembers
- true if only direct project members in the specified role should be notified, or false to also notify indirect memberspublic boolean equals(java.lang.Object obj)
equals
in class IdentifiableDto
public int compareTo(java.lang.Object obj)
compareTo
in interface java.lang.Comparable
compareTo
in class IdentifiableDto
public java.lang.String toString()
toString
in class IdentifiableDto
|
CodeBeamer 5.4.0.1-RC API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |