Exemplo n.º 1
0
 private Number readNumber(JsonLexer lexer) throws ParseException {
   expectCurrentToken(lexer, NUMBER);
   Number num = (Number) lexer.getValue();
   lexer.moveNext();
   return new BigDecimal(num.toString());
 }
Exemplo n.º 2
0
 private String readString(JsonLexer lexer) throws ParseException {
   expectCurrentToken(lexer, STRING);
   String str = unescape((String) lexer.getValue());
   lexer.moveNext();
   return str.toString();
 }
Exemplo n.º 3
0
 private Boolean readBoolean(JsonLexer lexer) throws ParseException {
   expectCurrentToken(lexer, BOOLEAN);
   Boolean bool = (Boolean) lexer.getValue();
   lexer.moveNext();
   return bool;
 }