private JsonToken DoTrueLiteral() { JsonToken token = JsonToken.INVALID; int length = Literals.TRUE_LENGTH; // char[] c = nextChars(length); CyclicCharArray c = NextCharsInQueue(length); if (LiteralUtil.IsTrue(c)) { token = TokenPool.TOKEN_TRUE; // nextToken = null; } else { // throw new JsonException("Unexpected string: " + Arrays.ToString(c), tailCharStream()); throw new DotJsonMiniException("Unexpected string: "); } return(token); }
private JsonToken DoTrueLiteral() { JsonToken token = JsonToken.INVALID; int length = Literals.TRUE_LENGTH; // char[] c = nextChars(length); CyclicCharArray c = NextCharsInQueue(length); if (parserPolicy.CaseInsensitiveLiterals ? LiteralUtil.IsTrueIgnoreCase(c) : LiteralUtil.IsTrue(c)) { token = TokenPool.TOKEN_TRUE; // nextToken = null; } else { // throw new UnexpectedSymbolException("Unexpected string: " + Arrays.toString(c), GetTailCharStream(), PeekCharStream()); throw new UnexpectedSymbolException("Unexpected string: " + (c == null ? "" : c.ToString()), GetTailCharStream(), PeekCharStream()); } return(token); }