Comment class

A WordPress Comment

Refer the above link to see which arguments are set based on different context modes (WordPressContext).

Constructors

Comment({@required int author, @required int post, @required String content, String authorEmail, String authorIp, String authorName, String authorUrl, String authorUserAgent, String date, String dateGmt, int parent: 0, CommentStatus status})
Comment.fromJson(Map<String, dynamic> json)

Properties

author ↔ int
ID of the author who is going to comment.
read / write
authorAvatarUrls AvatarUrls
read / write
authorEmail ↔ String
read / write
authorIp ↔ String
read / write
authorName ↔ String
read / write
authorUrl ↔ String
read / write
authorUserAgent ↔ String
read / write
content Content
Content of the comment.
read / write
date ↔ String
The date the comment was written, in the site's timezone.
read / write
dateGmt ↔ String
The date the comment was written, in GMT.
read / write
id ↔ int
ID of the comment.
read / write
read / write
read / write
parent ↔ int
ID of the parent comment in case of reply. This should be 0 in case of a new comment.
read / write
post ↔ int
ID of the post on which to comment.
read / write
status CommentStatus
This can only be set by an editor/administrator.
read / write
type CommentType
This can only be set by an editor/administrator.
read / write
hashCode → int
The hash code for this object.
read-only, inherited
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited

Methods

toJson() → Map<String, dynamic>
toString() → String
Returns a string representation of this object.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited

Operators

operator ==(dynamic other) → bool
The equality operator.
inherited