Package com.redwood.scheduler.api.model
Interface MonitorCondition
-
- All Superinterfaces:
ActionSubjectObject,Detail,NamedDetailObject,Readable,SchedulerEntity,SchedulerEntityComp
public interface MonitorCondition extends NamedDetailObject, ActionSubjectObject, Readable
A monitor condition defines when an alert is raised. A monitor condition is a boolean expression combined with a severity. If the expression is true, an alert of this severity is created. The expression can use the monitor values located in the same monitor node.
-
-
Field Summary
Fields Modifier and Type Field Description static StringOBJECT_TYPEString that will be returned fromSchedulerEntity.getObjectType()for "MonitorCondition" objects.static StringSEC_RANK_ALLThis rank is made of the following privileges:static StringSEC_RANK_NONEThis rank has no privileges assigned to it.static LongSEVERITY_FATALFatal severity definition for an Alert monitorstatic LongSEVERITY_GREENGreen severity definition for an Alert monitorstatic LongSEVERITY_NEVER_SETConstant that is used to indicate that a severity has never been set before.static LongSEVERITY_REDRed severity definition for an Alert monitorstatic LongSEVERITY_YELLOWYellow severity definition for an Alert monitorstatic QueryObjectType<MonitorCondition>TYPEType that can be used inSchedulerSession.executeObjectQuery(QueryObjectType, String, Object...).-
Fields inherited from interface com.redwood.scheduler.api.model.SchedulerEntity
ACTION_AUDIT, ACTION_EXPORT, ACTION_READ, BEHAVIOR_DEPRECATED, BEHAVIOR_NONE, BEHAVIOR_SYSTEM
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description SubjectgetActionSubject()Get the ActionSubject.StringgetExpression()Get the value for Expression.MonitorCheckgetMonitorCheck()Get the MonitorCheck.LonggetSeverity()Get the value for Severity.voidsetActionSubject(Subject newActionSubject)Set the value for ActionSubject.voidsetExpression(String newExpression)Set the value for Expression.voidsetSeverity(Long newSeverity)Set the value for Severity.-
Methods inherited from interface com.redwood.scheduler.api.model.interfaces.ActionSubjectObject
getActionSubjectUniqueId
-
Methods inherited from interface com.redwood.scheduler.api.model.NamedDetailObject
getComment, getDescription, getName, getSearchName, setComment, setDescription, setName
-
Methods inherited from interface com.redwood.scheduler.api.model.SchedulerEntity
canPerform, createSubjectObjectPrivilegeGrant, deleteObject, getAuditTrail, getAuditTrailSize, getBehavior, getEffectiveBehavior, getErrorNameEN, getErrorNameKey, getLLPVersion, getLOV, getLOVSupport, getObjectType, getParentSchedulerEntities, getRuntime, getSubjectObjectPrivilegeGrantBySubject, getSubjectObjectPrivilegeGrants, getUniqueId, getUrl, getUrl, isCreated, isDeletable, isDeleted, isModifiable, isModified, isSelectVersioned, processRelatedObjects, processRelatedObjects, processRelatedObjects, refreshObject, resetObject, resetObject, resetValuesToDefault, selectForRead
-
-
-
-
Field Detail
-
OBJECT_TYPE
static final String OBJECT_TYPE
String that will be returned fromSchedulerEntity.getObjectType()for "MonitorCondition" objects.- See Also:
- Constant Field Values
-
TYPE
static final QueryObjectType<MonitorCondition> TYPE
Type that can be used inSchedulerSession.executeObjectQuery(QueryObjectType, String, Object...).
-
SEVERITY_NEVER_SET
static final Long SEVERITY_NEVER_SET
Constant that is used to indicate that a severity has never been set before.
-
SEVERITY_GREEN
static final Long SEVERITY_GREEN
Green severity definition for an Alert monitor
-
SEVERITY_YELLOW
static final Long SEVERITY_YELLOW
Yellow severity definition for an Alert monitor
-
SEVERITY_RED
static final Long SEVERITY_RED
Red severity definition for an Alert monitor
-
SEVERITY_FATAL
static final Long SEVERITY_FATAL
Fatal severity definition for an Alert monitor
-
SEC_RANK_NONE
static final String SEC_RANK_NONE
This rank has no privileges assigned to it.- See Also:
- Constant Field Values
-
SEC_RANK_ALL
static final String SEC_RANK_ALL
This rank is made of the following privileges:- See Also:
- Constant Field Values
-
-
Method Detail
-
getSeverity
Long getSeverity()
Get the value for Severity. (The severity to assign to parent when the condition is violated) This value is mandatory, and therefore will not benullif this object has been retrieved from the database.- Returns:
- the field
- Throws:
com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException- This will be thrown if this method is called while the object is not attached to a session.
-
getExpression
String getExpression()
Get the value for Expression. (The Redwood expression to evaluate this condition with.)- Returns:
- the field
- Throws:
com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException- This will be thrown if this method is called while the object is not attached to a session.
-
setSeverity
void setSeverity(Long newSeverity)
Set the value for Severity. (The severity to assign to parent when the condition is violated) This value is mandatory.- Parameters:
newSeverity- the new value for Severity. If this isnull, then the object cannot be persisted.- Throws:
com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException- This will be thrown if this method is called while the object is not attached to a session.
-
setExpression
void setExpression(String newExpression)
Set the value for Expression. (The Redwood expression to evaluate this condition with.) This value is optional.- Parameters:
newExpression- the new value for Expression.- Throws:
com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException- This will be thrown if this method is called while the object is not attached to a session.
-
getMonitorCheck
MonitorCheck getMonitorCheck()
Get the MonitorCheck.- Returns:
- MonitorCheck
- Throws:
com.redwood.scheduler.api.exception.ObjectDeletedException- If this method is called when the object has been marked for deletion.com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException- If this method is called when the object has been removed from it's session.
-
getActionSubject
Subject getActionSubject()
Get the ActionSubject.- Specified by:
getActionSubjectin interfaceActionSubjectObject- Returns:
- ActionSubject
- Throws:
com.redwood.scheduler.api.exception.ObjectDeletedException- If this method is called when the object has been marked for deletion.com.redwood.scheduler.api.exception.ObjectNotAttachedToSessionException- If this method is called when the object has been removed from it's session.
-
setActionSubject
void setActionSubject(Subject newActionSubject)
Set the value for ActionSubject. This value is optional.- Parameters:
newActionSubject- is the object to set ActionSubject to. Who does this action execute as?
-
-