private String consumeTokenString() throws JsonParserException {
  reusableBuffer.setLength(0);
  while (true) {
    char c=stringChar();
switch (c) {
case '\"':
      return reusableBuffer.toString();
case '\\':
    int escape=advanceChar();
switch (escape) {
case -1:
    throw createParseException(null,"EOF encountered in the middle of a string escape",false);
case 'b':
  reusableBuffer.append('\b');
break;
case 'f':
reusableBuffer.append('\f');
break;
case 'n':
reusableBuffer.append('\n');
break;
case 'r':
reusableBuffer.append('\r');
break;
case 't':
reusableBuffer.append('\t');
break;
case '"':
case '/':
case '\\':
reusableBuffer.append((char)escape);
break;
case 'u':
reusableBuffer.append((char)(stringHexChar() << 12 | stringHexChar() << 8 | stringHexChar() << 4 | stringHexChar()));
break;
default :
throw createParseException(null,"Invalid escape: \\" + (char)escape,false);
}
break;
default :
reusableBuffer.append(c);
}
}
}

private String consumeTokenString ( ) throws JsonParserException { reusableBuffer . setLength ( 0 ) ; while ( true ) { char c = stringChar ( ) ; switch ( c ) { case '\"' : return reusableBuffer . toString ( ) ; case '\\' : int escape = advanceChar ( ) ; switch ( escape ) { case - 1 : throw createParseException ( null , "EOF encountered in the middle of a string escape" , false ) ; case 'b' : reusableBuffer . append ( '\b' ) ; break ; case 'f' : reusableBuffer . append ( '\f' ) ; break ; case 'n' : reusableBuffer . append ( '\n' ) ; break ; case 'r' : reusableBuffer . append ( '\r' ) ; break ; case 't' : reusableBuffer . append ( '\t' ) ; break ; case '"' : case '/' : case '\\' : reusableBuffer . append ( ( char ) escape ) ; break ; case 'u' : reusableBuffer . append ( ( char ) ( stringHexChar ( ) << 12 | stringHexChar ( ) << 8 | stringHexChar ( ) << 4 | stringHexChar ( ) ) ) ; break ; default : throw createParseException ( null , "Invalid escape: \\" + ( char ) escape , false ) ; } break ; default : reusableBuffer . append ( c ) ; } } }
steps through to the end of the current string token ( the unescaped double quote ) .
