@@ -85,7 +85,7 @@ public class ReaderBasedJsonParser // final in 2.3, earlier
85
85
/**
86
86
* Method called when caller wants to provide input buffer directly,
87
87
* and it may or may not be recyclable use standard recycle context.
88
- *
88
+ *
89
89
* @since 2.4
90
90
*/
91
91
public ReaderBasedJsonParser (IOContext ctxt , int features , Reader r ,
@@ -130,7 +130,7 @@ public ReaderBasedJsonParser(IOContext ctxt, int features, Reader r,
130
130
131
131
@ Override public ObjectCodec getCodec () { return _objectCodec ; }
132
132
@ Override public void setCodec (ObjectCodec c ) { _objectCodec = c ; }
133
-
133
+
134
134
@ Override
135
135
public int releaseBuffered (Writer w ) throws IOException {
136
136
int count = _inputEnd - _inputPtr ;
@@ -210,7 +210,7 @@ protected void _releaseBuffers() throws IOException {
210
210
}
211
211
}
212
212
}
213
-
213
+
214
214
/*
215
215
/**********************************************************
216
216
/* Public API, data access
@@ -1043,7 +1043,7 @@ private final JsonToken _nextTokenNotInObject(int i) throws IOException
1043
1043
}
1044
1044
return (_currToken = _handleOddValue (i ));
1045
1045
}
1046
-
1046
+
1047
1047
// note: identical to one in UTF8StreamJsonParser
1048
1048
@ Override
1049
1049
public final String nextTextValue () throws IOException
@@ -1184,15 +1184,15 @@ protected final JsonToken _parsePosNumber(int ch) throws IOException
1184
1184
if (ch == INT_0 ) {
1185
1185
return _parseNumber2 (false , startPtr );
1186
1186
}
1187
-
1187
+
1188
1188
/* First, let's see if the whole number is contained within
1189
1189
* the input buffer unsplit. This should be the common case;
1190
1190
* and to simplify processing, we will just reparse contents
1191
1191
* in the alternative case (number split on buffer boundary)
1192
1192
*/
1193
-
1193
+
1194
1194
int intLen = 1 ; // already got one
1195
-
1195
+
1196
1196
// First let's get the obligatory integer part:
1197
1197
int_loop :
1198
1198
while (true ) {
@@ -1306,7 +1306,7 @@ protected final JsonToken _parseNegNumber() throws IOException
1306
1306
return _parseNumber2 (true , startPtr );
1307
1307
}
1308
1308
int intLen = 1 ; // already got one
1309
-
1309
+
1310
1310
// First let's get the obligatory integer part:
1311
1311
int_loop :
1312
1312
while (true ) {
@@ -1503,7 +1503,7 @@ private char _verifyNLZ2() throws IOException
1503
1503
return '0' ;
1504
1504
}
1505
1505
++_inputPtr ; // skip previous zero
1506
- if (ch != '0' ) { // followed by other number; return
1506
+ if (ch != '0' ) { // followed by other number; return
1507
1507
break ;
1508
1508
}
1509
1509
}
@@ -1793,7 +1793,7 @@ protected JsonToken _handleOddValue(int i) throws IOException
1793
1793
_reportUnexpectedChar (i , "expected a valid value (number, String, array, object, 'true', 'false' or 'null')" );
1794
1794
return null ;
1795
1795
}
1796
-
1796
+
1797
1797
protected JsonToken _handleApos () throws IOException
1798
1798
{
1799
1799
char [] outBuf = _textBuffer .emptyAndGetCurrentSegment ();
@@ -1834,7 +1834,7 @@ protected JsonToken _handleApos() throws IOException
1834
1834
_textBuffer .setCurrentLength (outPtr );
1835
1835
return JsonToken .VALUE_STRING ;
1836
1836
}
1837
-
1837
+
1838
1838
private String _handleOddName2 (int startPtr , int hash , int [] codes ) throws IOException
1839
1839
{
1840
1840
_textBuffer .resetWithShared (_inputBuffer , startPtr , (_inputPtr - startPtr ));
@@ -1878,7 +1878,7 @@ private String _handleOddName2(int startPtr, int hash, int[] codes) throws IOExc
1878
1878
return _symbols .findSymbol (buf , start , len , hash );
1879
1879
}
1880
1880
}
1881
-
1881
+
1882
1882
@ Override
1883
1883
protected final void _finishString () throws IOException
1884
1884
{
@@ -2008,7 +2008,7 @@ protected final void _skipString() throws IOException
2008
2008
/* Internal methods, other parsing
2009
2009
/**********************************************************
2010
2010
*/
2011
-
2011
+
2012
2012
/**
2013
2013
* We actually need to check the character value here
2014
2014
* (to see if we have \n following \r).
@@ -2022,7 +2022,7 @@ protected final void _skipCR() throws IOException {
2022
2022
++_currInputRow ;
2023
2023
_currInputRowStart = _inputPtr ;
2024
2024
}
2025
-
2025
+
2026
2026
private final int _skipColon () throws IOException
2027
2027
{
2028
2028
if ((_inputPtr + 4 ) >= _inputEnd ) {
@@ -2044,7 +2044,7 @@ private final int _skipColon() throws IOException
2044
2044
if (i == INT_SLASH || i == INT_HASH ) {
2045
2045
return _skipColon2 (true );
2046
2046
}
2047
- ++_inputPtr ;
2047
+ ++_inputPtr ;
2048
2048
return i ;
2049
2049
}
2050
2050
}
@@ -2166,7 +2166,7 @@ private final int _skipColonFast(int ptr) throws IOException
2166
2166
_inputPtr = ptr -1 ;
2167
2167
return _skipColon2 (gotColon );
2168
2168
}
2169
-
2169
+
2170
2170
// Primary loop: no reloading, comment handling
2171
2171
private final int _skipComma (int i ) throws IOException
2172
2172
{
@@ -2225,7 +2225,7 @@ private final int _skipAfterComma2() throws IOException
2225
2225
}
2226
2226
throw _constructError ("Unexpected end-of-input within/between " +_parsingContext .getTypeDesc ()+" entries" );
2227
2227
}
2228
-
2228
+
2229
2229
private final int _skipWSOrEnd () throws IOException
2230
2230
{
2231
2231
// Let's handle first character separately since it is likely that
@@ -2253,7 +2253,7 @@ private final int _skipWSOrEnd() throws IOException
2253
2253
_throwInvalidSpace (i );
2254
2254
}
2255
2255
}
2256
-
2256
+
2257
2257
while (_inputPtr < _inputEnd ) {
2258
2258
i = (int ) _inputBuffer [_inputPtr ++];
2259
2259
if (i > INT_SPACE ) {
@@ -2309,7 +2309,7 @@ private int _skipWSOrEnd2() throws IOException
2309
2309
}
2310
2310
}
2311
2311
}
2312
-
2312
+
2313
2313
private void _skipComment () throws IOException
2314
2314
{
2315
2315
if (!isEnabled (Feature .ALLOW_COMMENTS )) {
@@ -2368,7 +2368,7 @@ private boolean _skipYAMLComment() throws IOException
2368
2368
_skipLine ();
2369
2369
return true ;
2370
2370
}
2371
-
2371
+
2372
2372
private void _skipLine () throws IOException
2373
2373
{
2374
2374
// Ok: need to find EOF or linefeed
@@ -2442,7 +2442,7 @@ protected char _decodeEscaped() throws IOException
2442
2442
}
2443
2443
return (char ) value ;
2444
2444
}
2445
-
2445
+
2446
2446
private final void _matchTrue () throws IOException {
2447
2447
int ptr = _inputPtr ;
2448
2448
if ((ptr + 3 ) < _inputEnd ) {
@@ -2563,9 +2563,9 @@ protected byte[] _decodeBase64(Base64Variant b64variant) throws IOException
2563
2563
}
2564
2564
}
2565
2565
int decodedData = bits ;
2566
-
2566
+
2567
2567
// then second base64 char; can't get padding yet, nor ws
2568
-
2568
+
2569
2569
if (_inputPtr >= _inputEnd ) {
2570
2570
loadMoreGuaranteed ();
2571
2571
}
@@ -2575,7 +2575,7 @@ protected byte[] _decodeBase64(Base64Variant b64variant) throws IOException
2575
2575
bits = _decodeBase64Escape (b64variant , ch , 1 );
2576
2576
}
2577
2577
decodedData = (decodedData << 6 ) | bits ;
2578
-
2578
+
2579
2579
// third base64 char; can be padding, but not ws
2580
2580
if (_inputPtr >= _inputEnd ) {
2581
2581
loadMoreGuaranteed ();
@@ -2655,7 +2655,7 @@ protected byte[] _decodeBase64(Base64Variant b64variant) throws IOException
2655
2655
protected void _reportInvalidToken (String matchedPart ) throws IOException {
2656
2656
_reportInvalidToken (matchedPart , "'null', 'true', 'false' or NaN" );
2657
2657
}
2658
-
2658
+
2659
2659
protected void _reportInvalidToken (String matchedPart , String msg ) throws IOException
2660
2660
{
2661
2661
StringBuilder sb = new StringBuilder (matchedPart );
0 commit comments