NodeToken Item_and_Text_Rule(Recovery next, int item) throws ParseException {
    Token key;
    NodeToken text;

    if (getToken(1).kind == item) {
        /* The item-token is found. */
        key = getNextToken();
        if (getToken(1).kind == TEXT_T) {
            /* The item-token is followed by TEXT-token. */
            text = makeNodeToken(getNextToken());
        } else {
            /* The item-token is not followed by TEXT-token. */
            Message.error(key.beginLine, key + " missing <quoted string>");
            text = makeNodeToken(TEXT_T, "<quoted string>");
        }
    } else if (getToken(1).kind == TEXT_T) {
        /* The item-token is missing, but the TEXT-token is there. */
        String str = tokenImage[item].replace('"', '\'');
        Message.error(getToken(1).beginLine, str + " keyword missing");
        text=makeNodeToken(getNextToken());
    } else {
        /* The Item-Text clause is missing at all. */
        StringBuffer str = new StringBuffer(tokenImage[item]);
        str.deleteCharAt(0);
        str.deleteCharAt(str.length()-1);
        Message.error(getToken(1).beginLine, str + "-clause missing");
        recovery(next);
        text = makeNodeToken(TEXT_T, "<quoted string>");
    }
    return text;
  }