Java tutorial
//package com.java2s; public class Main { public static boolean readFlagsBit(byte paramByte, int paramInt) { if (paramInt > 7) throw new IllegalAccessError("readFlagsBit error index>7!!! "); return (0x1 & paramByte << 7 - paramInt >> 7) == 1; } }