Java Void Function Object Is Not Subscriptable In Python