Class GeneratedComment

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable
    Direct Known Subclasses:
    Comment

    public abstract class GeneratedComment
    extends AbstractComment
    Generated class for type Comment.
    See Also:
    Serialized Form
    • Field Detail

      • CODE

        public static final java.lang.String CODE
        Qualifier of the Comment.code attribute
        See Also:
        Constant Field Values
      • PRIORITY

        public static final java.lang.String PRIORITY
        Qualifier of the Comment.priority attribute
        See Also:
        Constant Field Values
      • RELATEDITEMS

        public static final java.lang.String RELATEDITEMS
        Qualifier of the Comment.relatedItems attribute
        See Also:
        Constant Field Values
      • REPLIES

        public static final java.lang.String REPLIES
        Qualifier of the Comment.replies attribute
        See Also:
        Constant Field Values
      • ASSIGNEDTO

        public static final java.lang.String ASSIGNEDTO
        Qualifier of the Comment.assignedTo attribute
        See Also:
        Constant Field Values
      • COMMENTASSIGNEERELATION_SRC_ORDERED

        protected static java.lang.String COMMENTASSIGNEERELATION_SRC_ORDERED
        Relation ordering override parameter constants for CommentAssigneeRelation from ((comments))
      • COMMENTASSIGNEERELATION_TGT_ORDERED

        protected static java.lang.String COMMENTASSIGNEERELATION_TGT_ORDERED
      • COMMENTASSIGNEERELATION_MARKMODIFIED

        protected static java.lang.String COMMENTASSIGNEERELATION_MARKMODIFIED
        Relation disable markmodifed parameter constants for CommentAssigneeRelation from ((comments))
      • WATCHERS

        public static final java.lang.String WATCHERS
        Qualifier of the Comment.watchers attribute
        See Also:
        Constant Field Values
      • COMMENTWATCHERRELATION_SRC_ORDERED

        protected static java.lang.String COMMENTWATCHERRELATION_SRC_ORDERED
        Relation ordering override parameter constants for CommentWatcherRelation from ((comments))
      • COMMENTWATCHERRELATION_TGT_ORDERED

        protected static java.lang.String COMMENTWATCHERRELATION_TGT_ORDERED
      • COMMENTWATCHERRELATION_MARKMODIFIED

        protected static java.lang.String COMMENTWATCHERRELATION_MARKMODIFIED
        Relation disable markmodifed parameter constants for CommentWatcherRelation from ((comments))
      • COMPONENT

        public static final java.lang.String COMPONENT
        Qualifier of the Comment.component attribute
        See Also:
        Constant Field Values
      • COMMENTTYPE

        public static final java.lang.String COMMENTTYPE
        Qualifier of the Comment.commentType attribute
        See Also:
        Constant Field Values
      • DEFAULT_INITIAL_ATTRIBUTES

        protected static final java.util.Map<java.lang.String,​Item.AttributeMode> DEFAULT_INITIAL_ATTRIBUTES
    • Constructor Detail

      • GeneratedComment

        public GeneratedComment()
    • Method Detail

      • getAssignedTo

        public java.util.Collection<User> getAssignedTo​(SessionContext ctx)
        Generated method - Getter of the Comment.assignedTo attribute.
        Returns:
        the assignedTo
      • getAssignedTo

        public java.util.Collection<User> getAssignedTo()
        Generated method - Getter of the Comment.assignedTo attribute.
        Returns:
        the assignedTo
      • getAssignedToCount

        public long getAssignedToCount​(SessionContext ctx)
      • getAssignedToCount

        public long getAssignedToCount()
      • setAssignedTo

        public void setAssignedTo​(SessionContext ctx,
                                  java.util.Collection<User> value)
        Generated method - Setter of the Comment.assignedTo attribute.
        Parameters:
        value - the assignedTo
      • setAssignedTo

        public void setAssignedTo​(java.util.Collection<User> value)
        Generated method - Setter of the Comment.assignedTo attribute.
        Parameters:
        value - the assignedTo
      • addToAssignedTo

        public void addToAssignedTo​(SessionContext ctx,
                                    User value)
        Generated method - Adds value to assignedTo.
        Parameters:
        value - the item to add to assignedTo
      • addToAssignedTo

        public void addToAssignedTo​(User value)
        Generated method - Adds value to assignedTo.
        Parameters:
        value - the item to add to assignedTo
      • removeFromAssignedTo

        public void removeFromAssignedTo​(SessionContext ctx,
                                         User value)
        Generated method - Removes value from assignedTo.
        Parameters:
        value - the item to remove from assignedTo
      • removeFromAssignedTo

        public void removeFromAssignedTo​(User value)
        Generated method - Removes value from assignedTo.
        Parameters:
        value - the item to remove from assignedTo
      • getCode

        public java.lang.String getCode​(SessionContext ctx)
        Generated method - Getter of the Comment.code attribute.
        Returns:
        the code - unique identifier of the comment; will be generated if not set
      • getCode

        public java.lang.String getCode()
        Generated method - Getter of the Comment.code attribute.
        Returns:
        the code - unique identifier of the comment; will be generated if not set
      • setCode

        public void setCode​(SessionContext ctx,
                            java.lang.String value)
        Generated method - Setter of the Comment.code attribute.
        Parameters:
        value - the code - unique identifier of the comment; will be generated if not set
      • setCode

        public void setCode​(java.lang.String value)
        Generated method - Setter of the Comment.code attribute.
        Parameters:
        value - the code - unique identifier of the comment; will be generated if not set
      • getCommentType

        public CommentType getCommentType​(SessionContext ctx)
        Generated method - Getter of the Comment.commentType attribute.
        Returns:
        the commentType
      • getCommentType

        public CommentType getCommentType()
        Generated method - Getter of the Comment.commentType attribute.
        Returns:
        the commentType
      • setCommentType

        protected void setCommentType​(SessionContext ctx,
                                      CommentType value)
        Generated method - Setter of the Comment.commentType attribute.
        Parameters:
        value - the commentType
      • setCommentType

        protected void setCommentType​(CommentType value)
        Generated method - Setter of the Comment.commentType attribute.
        Parameters:
        value - the commentType
      • getComponent

        public Component getComponent​(SessionContext ctx)
        Generated method - Getter of the Comment.component attribute.
        Returns:
        the component
      • getComponent

        public Component getComponent()
        Generated method - Getter of the Comment.component attribute.
        Returns:
        the component
      • setComponent

        protected void setComponent​(SessionContext ctx,
                                    Component value)
        Generated method - Setter of the Comment.component attribute.
        Parameters:
        value - the component
      • setComponent

        protected void setComponent​(Component value)
        Generated method - Setter of the Comment.component attribute.
        Parameters:
        value - the component
      • createItem

        protected Item createItem​(SessionContext ctx,
                                  ComposedType type,
                                  Item.ItemAttributeMap allAttributes)
                           throws JaloBusinessException
        Description copied from class: Item
        Has to be implemented for each concrete subtype of item. This method is responsible for creating a new item instance ( by calling managers, ejb homes, etc. ) during ComposedType.newInstance(Map).

        In case this method uses any of the attribute values during creation it is required to override Item.getNonInitialAttributes(SessionContext, ItemAttributeMap) too.
        Sn example:

        
         public static final String MY_ATTRIBUTE = "someAttribute"; ... protected Item createItem(SessionContext
         ctx, ComposedType type, Map allAttributes ) throws JaloBusinessException { MyManager man = ... return
         man.createMyItem( (String)allAttributes.get(MY_ATTRIBUTE) );
         // here MY_ATTRIBUTE is used for creation, so it must not be set again } protected Map getNonInitialAttributes(
         SessionContext ctx, Map allAttributes ) { // let superclass remove its own initial attributes Map ret =
         super.getNonInitialAttributes( ctx, allAttributes );
         // remove MY_ATTRIBUTE from all attributes since if has already been set ret.remove(MY_ATTRIBUTE); return ret; }
        
         
        Overrides:
        createItem in class GeneratedAbstractComment
        Parameters:
        ctx - the current session context which this item is created within
        type - the actual item type ( since subtypes may not provide a own jalo class this may be different from the type which this method was implemented for )
        Returns:
        the new item instance
        Throws:
        JaloBusinessException - indicates an error during creation - any changes will be rollbacked
      • getPriority

        public java.lang.Integer getPriority​(SessionContext ctx)
        Generated method - Getter of the Comment.priority attribute.
        Returns:
        the priority - Priority of a comment
      • getPriority

        public java.lang.Integer getPriority()
        Generated method - Getter of the Comment.priority attribute.
        Returns:
        the priority - Priority of a comment
      • getPriorityAsPrimitive

        public int getPriorityAsPrimitive​(SessionContext ctx)
        Generated method - Getter of the Comment.priority attribute.
        Returns:
        the priority - Priority of a comment
      • getPriorityAsPrimitive

        public int getPriorityAsPrimitive()
        Generated method - Getter of the Comment.priority attribute.
        Returns:
        the priority - Priority of a comment
      • setPriority

        public void setPriority​(SessionContext ctx,
                                java.lang.Integer value)
        Generated method - Setter of the Comment.priority attribute.
        Parameters:
        value - the priority - Priority of a comment
      • setPriority

        public void setPriority​(java.lang.Integer value)
        Generated method - Setter of the Comment.priority attribute.
        Parameters:
        value - the priority - Priority of a comment
      • setPriority

        public void setPriority​(SessionContext ctx,
                                int value)
        Generated method - Setter of the Comment.priority attribute.
        Parameters:
        value - the priority - Priority of a comment
      • setPriority

        public void setPriority​(int value)
        Generated method - Setter of the Comment.priority attribute.
        Parameters:
        value - the priority - Priority of a comment
      • getRelatedItems

        public abstract java.util.Collection<Item> getRelatedItems​(SessionContext ctx)
        Generated method - Getter of the Comment.relatedItems attribute.
        Returns:
        the relatedItems - Related items of this comment
      • getRelatedItems

        public java.util.Collection<Item> getRelatedItems()
        Generated method - Getter of the Comment.relatedItems attribute.
        Returns:
        the relatedItems - Related items of this comment
      • setRelatedItems

        public abstract void setRelatedItems​(SessionContext ctx,
                                             java.util.Collection<Item> value)
        Generated method - Setter of the Comment.relatedItems attribute.
        Parameters:
        value - the relatedItems - Related items of this comment
      • setRelatedItems

        public void setRelatedItems​(java.util.Collection<Item> value)
        Generated method - Setter of the Comment.relatedItems attribute.
        Parameters:
        value - the relatedItems - Related items of this comment
      • getReplies

        public java.util.List<Reply> getReplies​(SessionContext ctx)
        Generated method - Getter of the Comment.replies attribute.
        Returns:
        the replies
      • getReplies

        public java.util.List<Reply> getReplies()
        Generated method - Getter of the Comment.replies attribute.
        Returns:
        the replies
      • setReplies

        public void setReplies​(SessionContext ctx,
                               java.util.List<Reply> value)
        Generated method - Setter of the Comment.replies attribute.
        Parameters:
        value - the replies
      • setReplies

        public void setReplies​(java.util.List<Reply> value)
        Generated method - Setter of the Comment.replies attribute.
        Parameters:
        value - the replies
      • addToReplies

        public void addToReplies​(SessionContext ctx,
                                 Reply value)
        Generated method - Adds value to replies.
        Parameters:
        value - the item to add to replies
      • addToReplies

        public void addToReplies​(Reply value)
        Generated method - Adds value to replies.
        Parameters:
        value - the item to add to replies
      • removeFromReplies

        public void removeFromReplies​(SessionContext ctx,
                                      Reply value)
        Generated method - Removes value from replies.
        Parameters:
        value - the item to remove from replies
      • removeFromReplies

        public void removeFromReplies​(Reply value)
        Generated method - Removes value from replies.
        Parameters:
        value - the item to remove from replies
      • getWatchers

        public java.util.Collection<Principal> getWatchers​(SessionContext ctx)
        Generated method - Getter of the Comment.watchers attribute.
        Returns:
        the watchers
      • getWatchers

        public java.util.Collection<Principal> getWatchers()
        Generated method - Getter of the Comment.watchers attribute.
        Returns:
        the watchers
      • getWatchersCount

        public long getWatchersCount​(SessionContext ctx)
      • getWatchersCount

        public long getWatchersCount()
      • setWatchers

        public void setWatchers​(SessionContext ctx,
                                java.util.Collection<Principal> value)
        Generated method - Setter of the Comment.watchers attribute.
        Parameters:
        value - the watchers
      • setWatchers

        public void setWatchers​(java.util.Collection<Principal> value)
        Generated method - Setter of the Comment.watchers attribute.
        Parameters:
        value - the watchers
      • addToWatchers

        public void addToWatchers​(SessionContext ctx,
                                  Principal value)
        Generated method - Adds value to watchers.
        Parameters:
        value - the item to add to watchers
      • addToWatchers

        public void addToWatchers​(Principal value)
        Generated method - Adds value to watchers.
        Parameters:
        value - the item to add to watchers
      • removeFromWatchers

        public void removeFromWatchers​(SessionContext ctx,
                                       Principal value)
        Generated method - Removes value from watchers.
        Parameters:
        value - the item to remove from watchers
      • removeFromWatchers

        public void removeFromWatchers​(Principal value)
        Generated method - Removes value from watchers.
        Parameters:
        value - the item to remove from watchers