package com.creatubbles.api.model.comment;

import android.support.annotation.NonNull;

import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import com.github.jasminb.jsonapi.annotations.Type;

/**
 * Created by Janek on 20.12.2017.
 */
public enum MentionType {

    USER("user"),
    GROUP("group"),
    CREATION("creation"),
    GALLERY("gallery"),
    PARTNER_APPLICATION("partner_application"),
    UNKNOWN("unknown");

    private String typeName;

    MentionType(String typeName) {
        this.typeName = typeName;
    }

    @JsonValue
    @NonNull
    public String getTypeName() {
        return typeName;
    }

    @JsonCreator
    public static MentionType fromName(String typeName) {
        for (MentionType mentionType : MentionType.values()) {
            if (mentionType.getTypeName().equals(typeName)) {
                return mentionType;
            }
        }
        return UNKNOWN;
    }
}

@@ -188,60 +188,8 @@
 lue;
-%0Aimport com.github.jasminb.jsonapi.annotations.Type;
 %0A%0A/*
@@ -388,24 +388,48 @@
 lication%22),%0A
+    HASHTAG(%22hashtag%22),%0A
     UNKNOWN(

Add Hashtag mention type to comments