Java Pass Function To Function Python