JSON-serialisable summary of a single post, used to answer forum and comment search requests. Wraps a Post (a Comment, ForumPost or ForumReply) with the fields a client needs to render a search result: the author, the note text, the posting date, and a link back to the content the post belongs to. Built from a Post via the toBean factory method rather than constructed directly, and produced by PostSearchResource for the forum and comment search JSON feed.
Properties
| Property | Returns | Description |
|---|---|---|
| contentDomain | String | Host name of the website the post's content belongs to, with a non-standard port appended if the site uses one. Used to build an absolute link back to the content. Null if the post has no associated website. |
| contentHref | String | Path to the comment, forum post or forum reply within its website, relative to the content domain. Resolved from the underlying Comment, ForumPost or ForumReply when the bean was built. |
| contentTitle | String | Title of the content this post relates to: the forum title for a forum post, the parent post's title for a forum reply, or the comment's content title for a comment. |
| date | long | Time the post was made, as milliseconds since the epoch. |
| id | long | Database id of the underlying post, comment or forum reply. |
| notes | String | Text content of the post or comment. |
| user | ProfileBean | Profile of the person who made the post, as a ProfileBean. Null if the underlying post has no poster. |
Methods
getId()
Returns: long
Database id of the underlying post, comment or forum reply.
getContentDomain()
Returns: String
Host name of the website the post's content belongs to, with a non-standard port appended if the site uses one. Used to build an absolute link back to the content. Null if the post has no associated website.
getContentHref()
Returns: String
Path to the comment, forum post or forum reply within its website, relative to the content domain. Resolved from the underlying Comment, ForumPost or ForumReply when the bean was built.
getContentTitle()
Returns: String
Title of the content this post relates to: the forum title for a forum post, the parent post's title for a forum reply, or the comment's content title for a comment.
getDate()
Returns: long
Time the post was made, as milliseconds since the epoch.
getNotes()
Returns: String
Text content of the post or comment.
getUser()
Returns: ProfileBean
Profile of the person who made the post, as a ProfileBean. Null if the underlying post has no poster.