Interface UserMessage

    • Method Detail

      • getText

        String getText()
        Get the value for Text. (The text of the UserMessage.) This value is mandatory, and therefore will not be null if 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.
      • getTitleText

        String getTitleText()
        Get the value for TitleText. (The title text of the UserMessage.) This value is mandatory, and therefore will not be null if 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.
      • getStatus

        ProcessMonitorItemStatus getStatus()
        Get the value for Status. (The status of the ProcessMonitorItem) This value is mandatory, and therefore will not be null if 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.
      • getReplyComment

        String getReplyComment()
        Get the value for ReplyComment. (The response comment)
        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.
      • getReplyTime

        DateTimeZone getReplyTime()
        Get the value for ReplyTime. (When was this message replied to?)
        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.
      • getNumAdditionalLines

        Long getNumAdditionalLines()
        Get the value for NumAdditionalLines. (The number of additional lines to this message.) This value is mandatory, and therefore will not be null if 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.
      • setText

        void setText​(String newText)
        Set the value for Text. (The text of the UserMessage.) This value is mandatory.
        Parameters:
        newText - the new value for Text. If this is null, 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.
      • setStatus

        void setStatus​(ProcessMonitorItemStatus newStatus)
        Set the value for Status. (The status of the ProcessMonitorItem) This value is mandatory.
        Parameters:
        newStatus - the new value for Status. If this is null, 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.
      • setReplyComment

        void setReplyComment​(String newReplyComment)
        Set the value for ReplyComment. (The response comment) This value is optional.
        Parameters:
        newReplyComment - the new value for ReplyComment.
        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.
      • start

        boolean start()
        Start the user message
        Returns:
        Returns true is the user message was started
      • notifyAssignee

        void notifyAssignee()
        Send a notification message to the currently assigned user
      • respond

        boolean respond()
        Return the message to the previous assignee.
        Returns:
        Returns true if the user message was returned
      • forward

        boolean forward​(Subject receiver)
        Forward the message to another party for them to comment.
        Parameters:
        receiver - The receiver of the message
        Returns:
        Returns true if the user message was forwarded
      • delegate

        boolean delegate​(Subject assignee)
        Delegate the message to another user to take ownership of the message.
        Parameters:
        assignee - The new assignee of the message
        Returns:
        Returns true if the user message was delegated
      • getAssignee

        Subject getAssignee()
        Get the currently responsible subject for the User Message
        Returns:
        Returns the currently assigned user for the message
      • getPreviousAssignee

        Subject getPreviousAssignee()
        Get the subject that was previously responsible for the User Message
        Returns:
        Returns the previously assigned user for the message
      • renderHistoryAsHTML

        String renderHistoryAsHTML​(String cssPrefix)
        Render the history of a UserMessage in an HTML table.
        Parameters:
        cssPrefix - Prefix to be appended to the styling of the HTML Table.
        Returns:
        The HTML Table.
      • renderHistoryAsText

        String renderHistoryAsText()
        Render the history of a UserMessage in a text table.
        Returns:
        The text Table.
      • canReply

        boolean canReply()
        Can a UserMessage be replied?
        Returns:
        True if the message can be replied
      • canDelegate

        boolean canDelegate()
        Can a UserMessage be delegated?
        Returns:
        True if the message can be delegated
      • canForward

        boolean canForward()
        Can a UserMessage be forwarded?
        Returns:
        True if the message can be forwarded
      • getUserMessageDefinitionResponse

        UserMessageDefinitionResponse getUserMessageDefinitionResponse()
        Get the UserMessageDefinitionResponse.
        Returns:
        UserMessageDefinitionResponse
        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.
      • getUserMessageDefinition

        UserMessageDefinition getUserMessageDefinition()
        Get the UserMessageDefinition.
        Returns:
        UserMessageDefinition
        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.
      • getJob

        Job getJob()
        Get the Job.
        Returns:
        Job
        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.
      • getRepliedSubject

        Subject getRepliedSubject()
        Get the RepliedSubject.
        Returns:
        RepliedSubject
        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.
      • setUserMessageDefinitionResponse

        void setUserMessageDefinitionResponse​(UserMessageDefinitionResponse newUserMessageDefinitionResponse)
        Set the value for UserMessageDefinitionResponse. This value is optional.
        Parameters:
        newUserMessageDefinitionResponse - is the object to set UserMessageDefinitionResponse to. The selected action of the UserMessageReply.
      • setUserMessageDefinition

        void setUserMessageDefinition​(UserMessageDefinition newUserMessageDefinition)
        Set the value for UserMessageDefinition. This value is optional.
        Parameters:
        newUserMessageDefinition - is the object to set UserMessageDefinition to. User Message this Reply is for
      • setJob

        void setJob​(Job newJob)
        Set the value for Job. This value is optional.
        Parameters:
        newJob - is the object to set Job to. The related UserMessage job that created this user message
      • checkCreatePrivilege

        RequiredPermission checkCreatePrivilege()
        Check whether or not the create action can be performed on this object.
        Returns:
        a RequiredPermission instance indicating whether the current user has the privilege. To check this, use isAllowed() on the returned permission.
      • checkViewPrivilege

        RequiredPermission checkViewPrivilege()
        Check whether or not the view action can be performed on this object.
        Returns:
        a RequiredPermission instance indicating whether the current user has the privilege. To check this, use isAllowed() on the returned permission.
      • checkEditPrivilege

        RequiredPermission checkEditPrivilege()
        Check whether or not the edit action can be performed on this object.
        Returns:
        a RequiredPermission instance indicating whether the current user has the privilege. To check this, use isAllowed() on the returned permission.
      • checkReplyPrivilege

        RequiredPermission checkReplyPrivilege()
        Check whether or not the reply action can be performed on this object.
        Returns:
        a RequiredPermission instance indicating whether the current user has the privilege. To check this, use isAllowed() on the returned permission.
      • checkDeletePrivilege

        RequiredPermission checkDeletePrivilege()
        Check whether or not the delete action can be performed on this object.
        Returns:
        a RequiredPermission instance indicating whether the current user has the privilege. To check this, use isAllowed() on the returned permission.