@Override
    public boolean equals(Object obj)
    {
        if (this == obj)
        {
            return true;
        }
        if (obj == null)
        {
            return false;
        }
        if (getClass() != obj.getClass())
        {
            return false;
        }
        final Token other = (Token) obj;
        if (code != other.code)
        {
            return false;
        }
        if (matched == null)
        {
            if (other.matched != null)
            {
                return false;
            }
        }
        else if (!matched.equals(other.matched))
        {
            return false;
        }
        return true;
    }