Skip to content

Commit 11889b8

Browse files
committed
Add type attribute to Comment model
1 parent d80090b commit 11889b8

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

src/main/java/org/zendesk/client/v2/model/Comment.java

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ public class Comment implements Serializable {
2323
private List<Attachment> attachments;
2424
private Date createdAt;
2525
private Boolean publicComment;
26+
private CommentType type;
27+
2628

2729
public Comment() {
2830
}
@@ -104,6 +106,15 @@ public void setPublic(Boolean isPublic) {
104106
this.publicComment = isPublic;
105107
}
106108

109+
@JsonProperty("type")
110+
public CommentType getType() {
111+
return type;
112+
}
113+
114+
public void setType(CommentType type) {
115+
this.type = type;
116+
}
117+
107118
@Override
108119
public String toString() {
109120
return "Comment{" + "id=" + id +
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
package org.zendesk.client.v2.model;
2+
3+
import com.fasterxml.jackson.annotation.JsonProperty;
4+
5+
/**
6+
* https://developer.zendesk.com/api-reference/ticketing/tickets/ticket_comments/
7+
*/
8+
public enum CommentType {
9+
10+
@JsonProperty("Comment") COMMENT,
11+
@JsonProperty("VoiceComment") VOICE_COMMENT;
12+
13+
}

0 commit comments

Comments
 (0)