stateNumericStart(str, offset) {
        if (offset >= str.length) {
            return -1;
        }
        if ((str.charCodeAt(offset) | TO_LOWER_BIT) === CharCodes.LOWER_X) {
            this.state = EntityDecoderState.NumericHex;
            this.consumed += 1;
            return this.stateNumericHex(str, offset + 1);
        }
        this.state = EntityDecoderState.NumericDecimal;
        return this.stateNumericDecimal(str, offset);
    }
Switches between the numeric decimal and hexadecimal states.

Equivalent to the `Numeric character reference state` in the HTML spec.

@param str The string containing the entity (or a continuation of the entity).
@param offset The current offset.
@returns The number of characters that were consumed, or -1 if the entity is incomplete.