@Override
    public boolean equals(Object obj)
    {
        if (this == obj) return true;
        if (obj == null) return false;
        if (!(obj instanceof Tag)) return false;
        Tag other = (Tag) obj;
        if (type == null)
        {
            if (other.getType() != null) return false;
        }
        else if (!type.equals(other.getType())) return false;
        if (value == null)
        {
            if (other.getValue() != null) return false;
        }
        else if (!value.equals(other.getValue())) return false;
        return true;
    }