target.apidocs.com.google.api.services.drive.model.Comment.html Maven / Gradle / Ivy
Comment (Drive API v2-rev20180830-1.26.0)
com.google.api.services.drive.model
Class Comment
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.drive.model.Comment
-
public final class Comment
extends com.google.api.client.json.GenericJson
A comment on a file in Google Drive.
This is the Java data model class that specifies how to parse/serialize into the JSON that is
transmitted over HTTP when working with the Drive API. For a detailed explanation see:
https://developers.google.com/api-client-library/java/google-http-java-client/json
- Author:
- Google, Inc.
-
-
Nested Class Summary
Nested Classes
Modifier and Type
Class and Description
static class
Comment.Context
The context of the file which is being commented on.
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
com.google.api.client.util.GenericData.Flags
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
-
Constructor Summary
Constructors
Constructor and Description
Comment()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
Comment
clone()
String
getAnchor()
A region of the document represented as a JSON string.
User
getAuthor()
The user who wrote this comment.
String
getCommentId()
The ID of the comment.
String
getContent()
The plain text content used to create this comment.
Comment.Context
getContext()
The context of the file which is being commented on.
com.google.api.client.util.DateTime
getCreatedDate()
The date when this comment was first created.
Boolean
getDeleted()
Whether this comment has been deleted.
String
getFileId()
The file which this comment is addressing.
String
getFileTitle()
The title of the file which this comment is addressing.
String
getHtmlContent()
HTML formatted content for this comment.
String
getKind()
This is always drive#comment.
com.google.api.client.util.DateTime
getModifiedDate()
The date when this comment or any of its replies were last modified.
List<CommentReply>
getReplies()
Replies to this post.
String
getSelfLink()
A link back to this comment.
String
getStatus()
The status of this comment.
Comment
set(String fieldName,
Object value)
Comment
setAnchor(String anchor)
A region of the document represented as a JSON string.
Comment
setAuthor(User author)
The user who wrote this comment.
Comment
setCommentId(String commentId)
The ID of the comment.
Comment
setContent(String content)
The plain text content used to create this comment.
Comment
setContext(Comment.Context context)
The context of the file which is being commented on.
Comment
setCreatedDate(com.google.api.client.util.DateTime createdDate)
The date when this comment was first created.
Comment
setDeleted(Boolean deleted)
Whether this comment has been deleted.
Comment
setFileId(String fileId)
The file which this comment is addressing.
Comment
setFileTitle(String fileTitle)
The title of the file which this comment is addressing.
Comment
setHtmlContent(String htmlContent)
HTML formatted content for this comment.
Comment
setKind(String kind)
This is always drive#comment.
Comment
setModifiedDate(com.google.api.client.util.DateTime modifiedDate)
The date when this comment or any of its replies were last modified.
Comment
setReplies(List<CommentReply> replies)
Replies to this post.
Comment
setSelfLink(String selfLink)
A link back to this comment.
Comment
setStatus(String status)
The status of this comment.
-
Methods inherited from class com.google.api.client.json.GenericJson
getFactory, setFactory, toPrettyString, toString
-
Methods inherited from class com.google.api.client.util.GenericData
entrySet, get, getClassInfo, getUnknownKeys, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, equals, hashCode, isEmpty, keySet, size, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
Method Detail
-
getAnchor
public String getAnchor()
A region of the document represented as a JSON string. See anchor documentation for details on
how to define and interpret anchor properties.
- Returns:
- value or
null
for none
-
setAnchor
public Comment setAnchor(String anchor)
A region of the document represented as a JSON string. See anchor documentation for details on
how to define and interpret anchor properties.
- Parameters:
anchor
- anchor or null
for none
-
getAuthor
public User getAuthor()
The user who wrote this comment.
- Returns:
- value or
null
for none
-
setAuthor
public Comment setAuthor(User author)
The user who wrote this comment.
- Parameters:
author
- author or null
for none
-
getCommentId
public String getCommentId()
The ID of the comment.
- Returns:
- value or
null
for none
-
setCommentId
public Comment setCommentId(String commentId)
The ID of the comment.
- Parameters:
commentId
- commentId or null
for none
-
getContent
public String getContent()
The plain text content used to create this comment. This is not HTML safe and should only be
used as a starting point to make edits to a comment's content.
- Returns:
- value or
null
for none
-
setContent
public Comment setContent(String content)
The plain text content used to create this comment. This is not HTML safe and should only be
used as a starting point to make edits to a comment's content.
- Parameters:
content
- content or null
for none
-
getContext
public Comment.Context getContext()
The context of the file which is being commented on.
- Returns:
- value or
null
for none
-
setContext
public Comment setContext(Comment.Context context)
The context of the file which is being commented on.
- Parameters:
context
- context or null
for none
-
getCreatedDate
public com.google.api.client.util.DateTime getCreatedDate()
The date when this comment was first created.
- Returns:
- value or
null
for none
-
setCreatedDate
public Comment setCreatedDate(com.google.api.client.util.DateTime createdDate)
The date when this comment was first created.
- Parameters:
createdDate
- createdDate or null
for none
-
getDeleted
public Boolean getDeleted()
Whether this comment has been deleted. If a comment has been deleted the content will be
cleared and this will only represent a comment that once existed.
- Returns:
- value or
null
for none
-
setDeleted
public Comment setDeleted(Boolean deleted)
Whether this comment has been deleted. If a comment has been deleted the content will be
cleared and this will only represent a comment that once existed.
- Parameters:
deleted
- deleted or null
for none
-
getFileId
public String getFileId()
The file which this comment is addressing.
- Returns:
- value or
null
for none
-
setFileId
public Comment setFileId(String fileId)
The file which this comment is addressing.
- Parameters:
fileId
- fileId or null
for none
-
getFileTitle
public String getFileTitle()
The title of the file which this comment is addressing.
- Returns:
- value or
null
for none
-
setFileTitle
public Comment setFileTitle(String fileTitle)
The title of the file which this comment is addressing.
- Parameters:
fileTitle
- fileTitle or null
for none
-
getHtmlContent
public String getHtmlContent()
HTML formatted content for this comment.
- Returns:
- value or
null
for none
-
setHtmlContent
public Comment setHtmlContent(String htmlContent)
HTML formatted content for this comment.
- Parameters:
htmlContent
- htmlContent or null
for none
-
getKind
public String getKind()
This is always drive#comment.
- Returns:
- value or
null
for none
-
setKind
public Comment setKind(String kind)
This is always drive#comment.
- Parameters:
kind
- kind or null
for none
-
getModifiedDate
public com.google.api.client.util.DateTime getModifiedDate()
The date when this comment or any of its replies were last modified.
- Returns:
- value or
null
for none
-
setModifiedDate
public Comment setModifiedDate(com.google.api.client.util.DateTime modifiedDate)
The date when this comment or any of its replies were last modified.
- Parameters:
modifiedDate
- modifiedDate or null
for none
-
getReplies
public List<CommentReply> getReplies()
Replies to this post.
- Returns:
- value or
null
for none
-
setReplies
public Comment setReplies(List<CommentReply> replies)
Replies to this post.
- Parameters:
replies
- replies or null
for none
-
getSelfLink
public String getSelfLink()
A link back to this comment.
- Returns:
- value or
null
for none
-
setSelfLink
public Comment setSelfLink(String selfLink)
A link back to this comment.
- Parameters:
selfLink
- selfLink or null
for none
-
getStatus
public String getStatus()
The status of this comment. Status can be changed by posting a reply to a comment with the
desired status. - "open" - The comment is still open. - "resolved" - The comment has been
resolved by one of its replies.
- Returns:
- value or
null
for none
-
setStatus
public Comment setStatus(String status)
The status of this comment. Status can be changed by posting a reply to a comment with the
desired status. - "open" - The comment is still open. - "resolved" - The comment has been
resolved by one of its replies.
- Parameters:
status
- status or null
for none
-
set
public Comment set(String fieldName,
Object value)
- Overrides:
set
in class com.google.api.client.json.GenericJson
-
clone
public Comment clone()
- Overrides:
clone
in class com.google.api.client.json.GenericJson
Copyright © 2011–2018 Google. All rights reserved.