static int jfind(S s, S in) { ret jfind(javaTok(s), in); } static int jfind(L tok, S in) { ret jfind(tok, 1, in); } static int jfind(L tok, int startIdx, S in) { ret jfind(tok, startIdx, in, null); } static int jfind(L tok, S in, O condition) { ret jfind(tok, 1, in, condition); } static int jfind(L tok, int startIdx, S in, O condition) { List tokin = javaTok(in); jfind_preprocess(tokin); ret jfind(tok, startIdx, tokin, condition); } // assumes you preprocessed tokin static int jfind(L tok, L tokin) { ret jfind(tok, 1, tokin); } static int jfind(L tok, int startIdx, L tokin) { ret jfind(tok, startIdx, tokin, null); } static int jfind(L tok, int startIdx, L tokin, O condition) { return findCodeTokens(tok, startIdx, false, toStringArray(codeTokensOnly(tokin)), condition); } static L jfind_preprocess(L tok) { for (S type : litlist("quoted", "id", "int")) replaceSublist(tok, ll("<", "", type, "", ">"), ll("<" + type + ">")); replaceSublist(tok, ll("\\", "", "*"), ll("\\*")); ret tok; }