protected void _loadMoreGuaranteed() throws IOException { if (!_loadMore()) { _reportInvalidEOF(); } }
protected void _loadMoreGuaranteed() throws IOException { if (!_loadMore()) { _reportInvalidEOF(); } }
/** * Method called when not even first 8 bytes are guaranteed * to come consecutively. Happens rarely, so this is offlined; * plus we'll also do full checks for escaping etc. */ protected String slowParseName() throws IOException { if (_inputPtr >= _inputEnd) { if (!_loadMore()) { _reportInvalidEOF(": was expecting closing '\"' for name", JsonToken.FIELD_NAME); } } int i = _inputBuffer[_inputPtr++] & 0xFF; if (i == INT_QUOTE) { // special case, "" return ""; } return parseEscapedName(_quadBuffer, 0, 0, i, 0); }
/** * Method called when not even first 8 bytes are guaranteed * to come consecutively. Happens rarely, so this is offlined; * plus we'll also do full checks for escaping etc. */ protected String slowParseName() throws IOException { if (_inputPtr >= _inputEnd) { if (!_loadMore()) { _reportInvalidEOF(": was expecting closing '\"' for name", JsonToken.FIELD_NAME); } } int i = _inputBuffer[_inputPtr++] & 0xFF; if (i == INT_QUOTE) { // special case, "" return ""; } return parseEscapedName(_quadBuffer, 0, 0, i, 0); }
_reportInvalidEOF(" in character escape sequence", JsonToken.VALUE_STRING); if (_inputPtr >= _inputEnd) { if (!_loadMore()) { _reportInvalidEOF(" in character escape sequence", JsonToken.VALUE_STRING);
private final void _skipComment() throws IOException { if (!isEnabled(Feature.ALLOW_COMMENTS)) { _reportUnexpectedChar('/', "maybe a (non-standard) comment? (not recognized as one since Feature 'ALLOW_COMMENTS' not enabled for parser)"); } // First: check which comment (if either) it is: if (_inputPtr >= _inputEnd && !_loadMore()) { _reportInvalidEOF(" in a comment", null); } int c = _inputBuffer[_inputPtr++] & 0xFF; if (c == INT_SLASH) { _skipLine(); } else if (c == INT_ASTERISK) { _skipCComment(); } else { _reportUnexpectedChar(c, "was expecting either '*' or '/' for a comment"); } }
_reportInvalidEOF(" in character escape sequence", JsonToken.VALUE_STRING); if (_inputPtr >= _inputEnd) { if (!_loadMore()) { _reportInvalidEOF(" in character escape sequence", JsonToken.VALUE_STRING);
private final void _skipComment() throws IOException { if (!isEnabled(JsonReadFeature.ALLOW_JAVA_COMMENTS)) { _reportUnexpectedChar('/', "maybe a (non-standard) comment? (not recognized as one since Feature 'ALLOW_COMMENTS' not enabled for parser)"); } // First: check which comment (if either) it is: if (_inputPtr >= _inputEnd && !_loadMore()) { _reportInvalidEOF(" in a comment", null); } int c = _inputBuffer[_inputPtr++] & 0xFF; if (c == INT_SLASH) { _skipLine(); } else if (c == INT_ASTERISK) { _skipCComment(); } else { _reportUnexpectedChar(c, "was expecting either '*' or '/' for a comment"); } }
_reportInvalidEOF(" within/between "+_parsingContext.typeDesc()+" entries", null); return -1;
_reportInvalidEOF(": was expecting closing '\'' for field name", JsonToken.FIELD_NAME); _reportInvalidEOF(" in field name", JsonToken.FIELD_NAME);
_reportInvalidEOF(" in field name", JsonToken.FIELD_NAME);
_reportInvalidEOF(" in a comment", null);
_reportInvalidEOF(" within/between "+_parsingContext.typeDesc()+" entries", null); return -1;
_reportInvalidEOF(": was expecting closing '\'' for field name", JsonToken.FIELD_NAME); _reportInvalidEOF(" in field name", JsonToken.FIELD_NAME);
_reportInvalidEOF(" in field name", JsonToken.FIELD_NAME);
_reportInvalidEOF(" in a comment", null);
_reportInvalidEOF(" in field name", JsonToken.FIELD_NAME);
_reportInvalidEOF(" in field name", JsonToken.FIELD_NAME);
_reportInvalidEOF(" in field name", JsonToken.FIELD_NAME);
_reportInvalidEOF(" in field name", JsonToken.FIELD_NAME);