Package net.pricefx.common.dto
Class WorkflowDTO.WatcherStepDTO
- Object
-
- WorkflowDTO.StepDTO<WorkflowDTO.WatcherStepDTO>
-
- WatcherStepDTO
-
- Enclosing class:
- WorkflowDTO
public static class WorkflowDTO.WatcherStepDTO extends WorkflowDTO.StepDTO<WorkflowDTO.WatcherStepDTO>
-
-
Field Summary
-
Fields inherited from class WorkflowDTO.StepDTO
alreadySatisfiedComment, emailAttachment, emailAttachmentTemplateName, properties, uniqueName, workflow
-
-
Constructor Summary
Constructors Constructor Description WatcherStepDTO(WorkflowDTO workflow, String userLoginName)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description WorkflowDTO.WatcherStepDTO
addProperty(String name, Object value)
void
fromMap(Map<String,Object> values)
String[]
getEmailListWatcher()
Gets the list of email addresses if specified as recipient for this nodeString
getReason()
Deprecated.List<String>
getReasons()
Returns the reason textString
getUserGroupWatcher()
Deprecated.Gets user group name in case of group watcher (or null otherwise)List<String>
getUserGroupWatchers()
Gets user group names in case of group watchers (or null otherwise)String
getUserWatcher()
Deprecated.Return the current watcher (or null if none set or if group watcher)List<String>
getUserWatchers()
Return the current watchers (or null if none set or if group watchers)WorkflowDTO.WatcherStepDTO
setReason(String reason)
WorkflowDTO.WatcherStepDTO
setReason(List<String> reasons)
Map<String,Object>
toMap()
WorkflowDTO.WatcherStepDTO
withEmailListWatcher(String... emails)
Instead of specifying a user name or a user group, arbitrary email addresses can be used here Last invoked of#withUserWatchers(String...)
,#withUserGroupWatchers(String...)
,#withEmailListWatcher(String...)
winsWorkflowDTO.WatcherStepDTO
withReasons(String... reasons)
Sets explanations for the watcher step.WorkflowDTO.WatcherStepDTO
withUserGroupWatcher(String userGroupUniqueName)
Deprecated.Specify user group as recipient Last invoked of#withUserWatcher(String)
,#withUserGroupWatcher(String)
,#withEmailListWatcher(String...)
winsWorkflowDTO.WatcherStepDTO
withUserGroupWatchers(String... userGroupUniqueNames)
Specify user groups as recipient Last invoked of#withUserWatchers(String...)
,#withUserGroupWatchers(String...)
,#withEmailListWatchers(String...)
winsWorkflowDTO.WatcherStepDTO
withUserWatcher(String userLoginName)
Deprecated.Specify a user as recipient Last invoked of#withUserWatcher(String)
,#withUserGroupWatcher(String)
,#withEmailListWatcher(String...)
winsWorkflowDTO.WatcherStepDTO
withUserWatchers(String... userLoginNames)
Specify users as recipients Last invoked of#withUserWatchers(String...)
,#withUserGroupWatchers(String...)
,#withEmailListWatcher(String...)
wins-
Methods inherited from class WorkflowDTO.StepDTO
equals, getAlreadySatisfiedComment, getEmailAttachment, getEmailAttachmentTemplateName, getProperties, getUniqueName, hashCode, readSingleValue, withAlreadySatisfied, withAlreadySatisfied, withEmailAttachment, withEmailAttachment, withEmailAttachmentTemplateName
-
-
-
-
Constructor Detail
-
WatcherStepDTO
public WatcherStepDTO(WorkflowDTO workflow, String userLoginName)
-
-
Method Detail
-
withUserWatcher
@Deprecated public WorkflowDTO.WatcherStepDTO withUserWatcher(String userLoginName)
Deprecated.Specify a user as recipient Last invoked of#withUserWatcher(String)
,#withUserGroupWatcher(String)
,#withEmailListWatcher(String...)
wins
-
withUserWatchers
public WorkflowDTO.WatcherStepDTO withUserWatchers(String... userLoginNames)
Specify users as recipients Last invoked of#withUserWatchers(String...)
,#withUserGroupWatchers(String...)
,#withEmailListWatcher(String...)
wins
-
withUserGroupWatcher
@Deprecated public WorkflowDTO.WatcherStepDTO withUserGroupWatcher(String userGroupUniqueName)
Deprecated.Specify user group as recipient Last invoked of#withUserWatcher(String)
,#withUserGroupWatcher(String)
,#withEmailListWatcher(String...)
wins
-
withUserGroupWatchers
public WorkflowDTO.WatcherStepDTO withUserGroupWatchers(String... userGroupUniqueNames)
Specify user groups as recipient Last invoked of#withUserWatchers(String...)
,#withUserGroupWatchers(String...)
,#withEmailListWatchers(String...)
wins
-
withEmailListWatcher
public WorkflowDTO.WatcherStepDTO withEmailListWatcher(String... emails)
Instead of specifying a user name or a user group, arbitrary email addresses can be used here Last invoked of#withUserWatchers(String...)
,#withUserGroupWatchers(String...)
,#withEmailListWatcher(String...)
wins
-
addProperty
public WorkflowDTO.WatcherStepDTO addProperty(String name, Object value)
-
setReason
public WorkflowDTO.WatcherStepDTO setReason(String reason)
-
setReason
public WorkflowDTO.WatcherStepDTO setReason(List<String> reasons)
-
withReasons
public WorkflowDTO.WatcherStepDTO withReasons(String... reasons)
Sets explanations for the watcher step.- Parameters:
reasons
- The reasons why each watcher is notified. The reasons match watchers. E.g. if you have 3 watchers (w1, w2, w3), you can specify up to 3 reasons (r1, r2, r3) and then r1 corresponds to w1, r2 to w2 etc. If you want to put multiple reasons to a single watcher, you need to join the strings and return a single combined reason in the code.- Returns:
-
getUserWatcher
public String getUserWatcher()
Deprecated.Return the current watcher (or null if none set or if group watcher)- Returns:
- The user name
-
getUserWatchers
public List<String> getUserWatchers()
Return the current watchers (or null if none set or if group watchers)- Returns:
- The user names
-
getReason
@Deprecated public String getReason()
Deprecated.Returns the reason text- Returns:
- The reason
-
getUserGroupWatcher
public String getUserGroupWatcher()
Deprecated.Gets user group name in case of group watcher (or null otherwise)- Returns:
-
getUserGroupWatchers
public List<String> getUserGroupWatchers()
Gets user group names in case of group watchers (or null otherwise)- Returns:
-
getEmailListWatcher
public String[] getEmailListWatcher()
Gets the list of email addresses if specified as recipient for this node- Returns:
-
toMap
public Map<String,Object> toMap()
- Overrides:
toMap
in classWorkflowDTO.StepDTO<WorkflowDTO.WatcherStepDTO>
-
fromMap
public void fromMap(Map<String,Object> values)
- Overrides:
fromMap
in classWorkflowDTO.StepDTO<WorkflowDTO.WatcherStepDTO>
-
-