Here you can find the source of readBoolean(ByteBuffer buff)
public static boolean readBoolean(ByteBuffer buff)
//package com.java2s; //License from project: LGPL import java.nio.ByteBuffer; public class Main { /**//from ww w . j av a 2s .co m * Reads one byte as a boolean. Its value is true if 1 and false if 0 */ public static boolean readBoolean(ByteBuffer buff) { return buff.get() == 1; } }