Here you can find the source of memchr(boolean[] ary, int start, int len, boolean find)
public static int memchr(boolean[] ary, int start, int len, boolean find)
//package com.java2s; //License from project: LGPL public class Main { public static int memchr(boolean[] ary, int start, int len, boolean find) { for (int i = 0; i < len; i++) { if (ary[i + start] == find) return i + start; }/*from w w w . j a v a 2 s . c o m*/ return -1; } }