org.telscenter.sail.webapp.domain.brainstorm.answer
Interface Answer

All Superinterfaces:
Comparable<Answer>, Persistable, Serializable
All Known Implementing Classes:
AnswerImpl

public interface Answer
extends Persistable, Comparable<Answer>

An answer is a first-level post to a Brainstorm question.

Version:
$Id$
Author:
Hiroki Terashima

Method Summary
 void addComment(Comment comment)
          Adds a comment to this answer.
 void addRevision(Revision revision)
          Adds a revision to this answer.
 Set<AnswerTag> getAnswerTags()
          Returns all of the AnserTags that are on this Answer.
 Set<Comment> getComments()
          Get all the comments for this answer.
 Group getGroup()
          Returns the Group that this answer was posted to, and members in the group can see this answer
 Set<Revision> getRevisions()
          Gets all the revisions in this Answer.
 WISEWorkgroup getWorkgroup()
          Get the WISEWorkgroup that authored this answer
 Set<WISEWorkgroup> getWorkgroupsThatFoundAnswerHelpful()
          Returns a Set of Workgroups that found this answer helpful.
 boolean isAnonymous()
          Indicates whether this answer should be posted as anonymous.
 void markAsHelpful(WISEWorkgroup workgroup)
          Saves a workgroup that found this Answer to be helpful.
 void setAnonymous(boolean isAnonymous)
          Indicates whether this answer should be posted as anonymous.
 void setGroup(Group group)
          Sets the Group that this answer was posted to, and members in the group can see this answer
 void setWorkgroup(WISEWorkgroup workgroup)
          Set the WISEWorkgroup that authored this answer
 void unmarkAsHelpful(WISEWorkgroup workgroup)
          Indicates that the specified workgroup no longer finds this Answer helpful.
 boolean workgroupMarkedAnswerHelpful(WISEWorkgroup workgroup)
          Returns whether the specified workgroup found this answer as helpful.
 
Methods inherited from interface net.sf.sail.webapp.domain.Persistable
getId
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Method Detail

getRevisions

Set<Revision> getRevisions()
Gets all the revisions in this Answer.

Returns:

getGroup

Group getGroup()
Returns the Group that this answer was posted to, and members in the group can see this answer

Returns:
Group which group can see this answer

setGroup

void setGroup(Group group)
Sets the Group that this answer was posted to, and members in the group can see this answer

Parameters:
Group - which group can see this answer

getWorkgroup

WISEWorkgroup getWorkgroup()
Get the WISEWorkgroup that authored this answer

Returns:
WISEWorkgroup

setWorkgroup

void setWorkgroup(WISEWorkgroup workgroup)
Set the WISEWorkgroup that authored this answer

Parameters:
WISEWorkgroup -

getComments

Set<Comment> getComments()
Get all the comments for this answer.

Returns:
Set of Comments

addComment

void addComment(Comment comment)
Adds a comment to this answer.

Parameters:
Comment - to add.

addRevision

void addRevision(Revision revision)
Adds a revision to this answer.

Parameters:
revision -

isAnonymous

boolean isAnonymous()
Indicates whether this answer should be posted as anonymous. Indicating as true will mean that all of the revisions that the author of this answer has done will also be posted as anonymous. This flag does not affect the anonimity of the comments.

Returns:
true iff this post should be posted as anonymous.

setAnonymous

void setAnonymous(boolean isAnonymous)
Indicates whether this answer should be posted as anonymous. Indicating as true will mean that all of the revisions that the author of this answer has done will also be posted as anonymous. This flag does not affect the anonimity of the comments.

Parameters:
true - iff this post should be posted as anonymous.

markAsHelpful

void markAsHelpful(WISEWorkgroup workgroup)
Saves a workgroup that found this Answer to be helpful. If this workgroup has already indicated this before, nothing will happen.

Parameters:
Workgroup - that found this answer helpful.

getWorkgroupsThatFoundAnswerHelpful

Set<WISEWorkgroup> getWorkgroupsThatFoundAnswerHelpful()
Returns a Set of Workgroups that found this answer helpful.

Returns:
Set of Workgroups that found this answer helpful.

getAnswerTags

Set<AnswerTag> getAnswerTags()
Returns all of the AnserTags that are on this Answer.

Returns:

unmarkAsHelpful

void unmarkAsHelpful(WISEWorkgroup workgroup)
Indicates that the specified workgroup no longer finds this Answer helpful.

Parameters:
workgroup -

workgroupMarkedAnswerHelpful

boolean workgroupMarkedAnswerHelpful(WISEWorkgroup workgroup)
Returns whether the specified workgroup found this answer as helpful.

Parameters:
workgroup -
Returns:


Copyright © 2012. All Rights Reserved.