FastJsonObjectInput implements ObjectInput { @Override public boolean readBool() throws IOException { return read(boolean.class); } FastJsonObjectInput(InputStream in);  FastJsonObjectInput(Reader reader); @Override boolean readBool(); @Override byte readByte(); @Override short readShort(); @Override int readInt(); @Override long readLong(); @Override float readFloat(); @Override double readDouble(); @Override String readUTF(); @Override byte[] readBytes(); @Override Object readObject(); @Override T readObject(Class<T> cls); @Override @SuppressWarnings("unchecked") T readObject(Class<T> cls, Type type);  }
@Test public void testReadBool() throws IOException { fastJsonObjectInput = new FastJsonObjectInput(new ByteArrayInputStream("true".getBytes())); boolean result = fastJsonObjectInput.readBool(); assertThat(result, is(true)); fastJsonObjectInput = new FastJsonObjectInput(new StringReader("false")); result = fastJsonObjectInput.readBool(); assertThat(result, is(false)); }