CommentOperations
and Comment
instead.@Deprecated public interface Comment
Comment
represents a single comment. It can also contain other Comment
s.Modifier and Type | Field and Description |
---|---|
static String |
COMMENTID_SEPARATOR
Deprecated.
|
static String |
FLAG_PATH_PREFIX
Deprecated.
The location where the tally flags are stored relative to the comment.
|
static String |
FORWARD_REPLICATED
Deprecated.
The property name for forward replication
|
static String |
NODE_TYPE
Deprecated.
The comment node type.
|
static String |
PARAM_BOTCHECK
Deprecated.
The name of the dynamically added parameter that needs to be present to make sure the form was posted by a
human being.
|
static String |
PROP_APPROVED
Deprecated.
The property name for the approval status.
|
static String |
PROP_AUTHORIZABLE_ID
Deprecated.
The property name for the authorizableId.
|
static String |
PROP_CLOSED
Deprecated.
The property name for the 'closed' flag.
|
static String |
PROP_DATE
Deprecated.
The property name for the date this comment has been added.
|
static String |
PROP_DELETE_ATTACHMENTS
Deprecated.
The property name for deleting attachments
|
static String |
PROP_FILE_UPLOAD
Deprecated.
The property name for the file upload.
|
static String |
PROP_FLAG_ALLOW_COUNT
Deprecated.
|
static String |
PROP_FLAG_HIDE
Deprecated.
The property name for the boolean indicating the comment is hidden because it has been flagged enough.
|
static String |
PROP_FLAG_REASON
Deprecated.
|
static String |
PROP_FLAGGED
Deprecated.
The property name for the spam flag.
|
static String |
PROP_IP_ADDRESS
Deprecated.
The property name for the IP address.
|
static String |
PROP_MESSAGE
Deprecated.
The property name for the message of this comment.
|
static String |
PROP_MODERATE
Deprecated.
The property to trigger moderation on edits.
|
static String |
PROP_REFERER
Deprecated.
The property name for the referer.
|
static String |
PROP_RESOURCE_TYPE
Deprecated.
The property name for the resource type.
|
static String |
PROP_SPAM
Deprecated.
The property name for the spam flag.
|
static String |
PROP_USER_AGENT
Deprecated.
The property name for the user agent.
|
static String |
REQ_ATTR_REDIRECT
Deprecated.
The forward redirect attribute using by form manager.
|
static String |
RESOURCE_TYPE
Deprecated.
The comment resource type.
|
static String |
VALUE_BOTCHECK
Deprecated.
The value of the dynamically added parameter that needs to be present to make sure the form was posted by a
human being.
|
Modifier and Type | Method and Description |
---|---|
String |
addAttachment(String name,
Binary data,
String contentType)
Deprecated.
use
addAttachemnt(Comment, String, java.io.InputStream, String) |
void |
addAttachments(List<javax.activation.DataSource> attachments)
Deprecated.
Add multiple attachments for this comment.
|
int |
countComments()
Deprecated.
Returns the number of direct comments.
|
int |
countComments(WCMMode wcmMode)
Deprecated.
Returns the number of direct comments based on .
|
void |
deleteAttachment(String attPath)
Deprecated.
use {@link removeAttachment(String)
|
Map<String,Attachment> |
getAttachments()
Deprecated.
|
CollabUser |
getAuthor()
Deprecated.
Returns the author of this comment.
|
Iterator<Comment> |
getComments()
Deprecated.
Returns the first level of comments in chronological order.
|
CommentSystem |
getCommentSystem()
Deprecated.
Returns the system this comment is in.
|
Resource |
getComponent()
Deprecated.
Returns the resource of the component responsible to draw these comments.
|
Date |
getDate()
Deprecated.
Returns the date this comment was added on.
|
String |
getFullUrl(SlingHttpServletRequest request)
Deprecated.
Returns the absolute URL of this comment, including scheme, server name and port.
|
String |
getId()
Deprecated.
Returns the ID of this comment.
|
String |
getMessage()
Deprecated.
Returns the message of this comment.
|
String |
getPath()
Deprecated.
Returns the path of this comment.
|
ValueMap |
getProperties()
Deprecated.
Returns the Properties valuemap for the node.
|
<T> T |
getProperty(String name,
Class<T> type)
Deprecated.
Get a named property and convert it into the given type.
|
<T> T |
getProperty(String name,
T defaultValue)
Deprecated.
Get a named property and convert it into the given type.
|
String |
getRefreshUrl()
Deprecated.
Returns the URL to refresh this comment, circumventing caching.
|
Resource |
getResource()
Deprecated.
Returns the underlying resource.
|
String |
getUrl()
Deprecated.
Returns the relative URL of this comment.
|
boolean |
hasComments()
Deprecated.
Checks whether there are any comments or not.
|
boolean |
hasComments(WCMMode wcmMode)
Deprecated.
Checks whether there are any comments or not based on the specified WCM mode.
|
boolean |
isApproved()
Deprecated.
Checks whether this comment is approved (in case comments are moderated).
|
boolean |
isClosed()
Deprecated.
Checks whether this comment is closed.
|
boolean |
isDenied()
Deprecated.
Checks whether this comment is denied (in case comments are moderated).
|
boolean |
isFlagged()
Deprecated.
Checks whether this comment is flagged as inappropriate.
|
boolean |
isFlaggedHidden()
Deprecated.
Checks whether this comment is hidden from flagging (before moderators have allowed or denied it).
|
boolean |
isPending()
Deprecated.
Checks whether this comment is pending approval (in case comments are moderated).
|
boolean |
isSpam()
Deprecated.
Checks whether this comment is marked as spam.
|
boolean |
isTopLevel()
Deprecated.
Return true if this is a top level comment.
|
void |
setDate(Date date)
Deprecated.
Sets the date this comment was added on.
|
static final String NODE_TYPE
static final String RESOURCE_TYPE
static final String PROP_RESOURCE_TYPE
static final String PROP_MESSAGE
static final String PROP_DATE
static final String PROP_APPROVED
static final String PROP_SPAM
static final String PROP_FLAG_HIDE
static final String PROP_FLAGGED
static final String PROP_CLOSED
static final String FLAG_PATH_PREFIX
static final String PROP_IP_ADDRESS
static final String PROP_USER_AGENT
static final String PROP_REFERER
static final String PARAM_BOTCHECK
static final String VALUE_BOTCHECK
static final String PROP_AUTHORIZABLE_ID
static final String PROP_FILE_UPLOAD
static final String PROP_DELETE_ATTACHMENTS
static final String FORWARD_REPLICATED
static final String PROP_MODERATE
static final String COMMENTID_SEPARATOR
static final String REQ_ATTR_REDIRECT
static final String PROP_FLAG_REASON
static final String PROP_FLAG_ALLOW_COUNT
Iterator<Comment> getComments()
int countComments()
int countComments(WCMMode wcmMode)
wcmMode
- The WCM modeboolean hasComments()
true
if there are comments, false
otherwiseboolean hasComments(WCMMode wcmMode)
wcmMode
- The WCM modetrue
if there are comments, false
otherwiseResource getComponent()
<T> T getProperty(String name, Class<T> type)
name
- The name of the propertytype
- The class of the typeValueMap
<T> T getProperty(String name, T defaultValue)
name
- The name of the propertydefaultValue
- The default value to use if the named property does not exist or cannot be converted to the
requested type. The default value is also used to define the type to convert the value to. If this
is null any existing property is not converted.ValueMap
Resource getResource()
String getPath()
String getUrl()
String getFullUrl(SlingHttpServletRequest request)
request
- The sling requestString getRefreshUrl()
CollabUser getAuthor()
String getMessage()
Date getDate()
void setDate(Date date) throws CommentException
date
- The dateCommentException
- if date cannot be setboolean isPending()
true
if comment is pending approval, false
otherwiseboolean isApproved()
true
if comment is approved or unmoderated, false
otherwiseboolean isDenied()
true
if comment is denied, false
otherwiseboolean isSpam()
true
if comment is marked as spam, false
otherwiseboolean isFlagged()
true
if comment is flagged, false
otherwiseboolean isFlaggedHidden()
true
if comment is hidden from being flagged enough, false
otherwiseboolean isClosed()
true
if comment is closed, false
otherwiseString getId()
CommentSystem getCommentSystem()
@Deprecated String addAttachment(String name, Binary data, String contentType) throws CommentException
addAttachemnt(Comment, String, java.io.InputStream, String)
name
- Name of the filedata
- Binary representation of the filecontentType
- Content Type of the fileCommentException
- If the comment cannot be created@Deprecated void deleteAttachment(String attPath) throws CommentException
attPath
- Attachment Path of the file.CommentException
- If the comment cannot be createdvoid addAttachments(List<javax.activation.DataSource> attachments)
attachments
- List of attached files in the DataSource format.boolean isTopLevel()
ValueMap getProperties()
Map<String,Attachment> getAttachments()
"Copyright © 2006 - 2015 Adobe Systems Incorporated. All Rights Reserved"