Class ReplyEntity
java.lang.Object
org.silverpeas.components.questionreply.web.ReplyEntity
- All Implemented Interfaces:
Serializable,org.silverpeas.core.web.rs.WebEntity
- Author:
- emmanuel.hugonnet@silverpeas.org
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic List<ReplyEntity>fromReplies(Iterable<Reply> replies, String lang) Creates several new reply entities from the specified list of replies.static ReplyEntityCreates a new reply entity from the specified reply.org.silverpeas.core.webapi.attachment.AttachmentEntity[]getId()getTitle()getURI()inthashCode()booleanbooleantoReply()Gets the reply business objet this entity represent.toString()withAttachments(Collection<org.silverpeas.core.contribution.attachment.model.SimpleDocument> attachmentDetails) Sets a URI to this entity.withProfile(org.silverpeas.core.admin.user.model.SilverpeasRole profile) Sets the accessing user profile to this entity.Sets a URI to this entity.
-
Constructor Details
-
ReplyEntity
protected ReplyEntity()
-
-
Method Details
-
getContent
-
getCreationDate
-
getCreatorId
-
getCreatorName
-
getId
-
isPrivateReply
public boolean isPrivateReply() -
isPublicReply
public boolean isPublicReply() -
getTitle
-
getLanguage
-
getAttachments
public org.silverpeas.core.webapi.attachment.AttachmentEntity[] getAttachments() -
getURI
- Specified by:
getURIin interfaceorg.silverpeas.core.web.rs.WebEntity
-
equals
-
hashCode
public int hashCode() -
fromReply
Creates a new reply entity from the specified reply.- Parameters:
reply- the reply to entitify.- Returns:
- the entity representing the specified reply.
-
fromReplies
Creates several new reply entities from the specified list of replies.- Parameters:
replies- the list of replies to entitify.- Returns:
- a list of entities representing each of then one of the specified replies.
-
toReply
Gets the reply business objet this entity represent.- Returns:
- a reply instance.
-
withURI
Sets a URI to this entity. With this URI, it can then be accessed through the Web.- Parameters:
uri- the web entity URI.- Returns:
- itself.
-
withAttachments
public ReplyEntity withAttachments(Collection<org.silverpeas.core.contribution.attachment.model.SimpleDocument> attachmentDetails) Sets a URI to this entity. With this URI, it can then be accessed through the Web.- Parameters:
attachmentDetails- a collection of SimpleDocument- Returns:
- itself.
-
withProfile
Sets the accessing user profile to this entity. With this profile the status of this reply can be defined.- Parameters:
profile- the profile of the accessing user.- Returns:
- itself.
-
toString
-