aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main/java/com/juick/Tag.java12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/main/java/com/juick/Tag.java b/src/main/java/com/juick/Tag.java
index 3cee3358..119aad99 100644
--- a/src/main/java/com/juick/Tag.java
+++ b/src/main/java/com/juick/Tag.java
@@ -17,11 +17,13 @@
*/
package com.juick;
+import java.util.Objects;
+
/**
*
* @author Ugnich Anton
*/
-public class Tag implements Comparable<Tag> {
+public class Tag {
public String Name = null;
public int TID = 0;
@@ -29,7 +31,11 @@ public class Tag implements Comparable<Tag> {
public int UsageCnt = 0;
@Override
- public int compareTo(Tag o) {
- return this.Name.compareTo(o.Name);
+ public boolean equals(Object o) {
+ boolean equal = false;
+ if (o != null && o instanceof Tag) {
+ equal = Objects.equals(Name, ((Tag) o).Name);
+ }
+ return equal;
}
}