aboutsummaryrefslogtreecommitdiffstats
path: root/main/src/cgeo/geocaching/connector/gc/GCSmiliesProvider.java
diff options
context:
space:
mode:
Diffstat (limited to 'main/src/cgeo/geocaching/connector/gc/GCSmiliesProvider.java')
-rw-r--r--main/src/cgeo/geocaching/connector/gc/GCSmiliesProvider.java11
1 files changed, 8 insertions, 3 deletions
diff --git a/main/src/cgeo/geocaching/connector/gc/GCSmiliesProvider.java b/main/src/cgeo/geocaching/connector/gc/GCSmiliesProvider.java
index eba9301..071c3b0 100644
--- a/main/src/cgeo/geocaching/connector/gc/GCSmiliesProvider.java
+++ b/main/src/cgeo/geocaching/connector/gc/GCSmiliesProvider.java
@@ -1,5 +1,7 @@
package cgeo.geocaching.connector.gc;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
public class GCSmiliesProvider {
public enum Smiley {
@@ -24,9 +26,10 @@ public class GCSmiliesProvider {
DISAPPROVE("V"),
QUESTION("?");
+ @NonNull
public final String text;
- Smiley(final String text) {
+ Smiley(@NonNull final String text) {
this.text = text;
}
@@ -35,12 +38,14 @@ public class GCSmiliesProvider {
}
}
+ @NonNull
public static Smiley[] getSmilies() {
return Smiley.values();
}
- public static Smiley getSmiley(int itemId) {
- for (Smiley smiley : getSmilies()) {
+ @Nullable
+ public static Smiley getSmiley(final int itemId) {
+ for (final Smiley smiley : getSmilies()) {
if (smiley.getItemId() == itemId) {
return smiley;
}