// all of the tabs have the same role, so we can just find out what that is here and use it for all the tabs
jobjectjtabJavaRole=(*env)->GetObjectArrayElement(env,jtabsAndRoles,1);// the array entries alternate between tab/role, starting with tab. so the first role is entry 1.