1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package com.atlassian.jira.rest.client.domain;
18
19 import com.google.common.base.Objects;
20
21 import javax.annotation.Nullable;
22 import java.net.URI;
23
24
25
26
27
28
29 public class IssueType extends BasicIssueType {
30 private final String description;
31 private final URI iconUri;
32
33 public IssueType(URI self, @Nullable Long id, String name, boolean isSubtask, String description, URI iconUri) {
34 super(self, id, name, isSubtask);
35 this.description = description;
36 this.iconUri = iconUri;
37 }
38
39 public String getDescription() {
40 return description;
41 }
42
43 public URI getIconUri() {
44 return iconUri;
45 }
46
47
48
49
50 @Override
51 protected Objects.ToStringHelper getToStringHelper() {
52 return super.getToStringHelper().
53 add("description", description).
54 add("iconUri", iconUri);
55 }
56
57 @Override
58 public boolean equals(Object obj) {
59 if (obj instanceof IssueType) {
60 IssueType that = (IssueType) obj;
61 return super.equals(obj)
62 && Objects.equal(this.description, that.description)
63 && Objects.equal(this.iconUri, that.iconUri);
64 }
65 return false;
66 }
67
68 @Override
69 public int hashCode() {
70 return Objects.hashCode(super.hashCode(), description, iconUri);
71 }
72
73 }