question: public static int classIndex ( int luaState , Class clazz , String searchName ) throws LuaException { synchronized ( LuaStateFactory . getExistingState ( luaState ) ) { int res ; res = checkField ( luaState , clazz , searchName ) ; if ( res != 0 ) { return 1 ; } res = checkMethod ( luaState , clazz , searchName ) ; if ( res != 0 ) { return 2 ; } return 0 ; } }
target:  Java function to be called when a java Class metamethod __index is called. This function returns 1 if there is a field with searchName and 2 if there is a method if the searchName