if (po != null) {
}  if (po != null) { if (rev.isCollection()) {
                public void onRole(Role role) {                    // Instead of storing the old value and removing it we                    // could simply do a delete of the component and count on                    // the code in delete to add the proper remove. Not sure                    // what makes the most sense yet.                    Object old = null;                    if (role.isComponent() || role.isReversable()) {                        old = get(oid, role);                    }                    addEvent(new SetEvent(Session.this, oid, role, value));                    if (role.isComponent()) {                        PersistentObject po = (PersistentObject) old;                        if (po != null) {                            delete(po.getOID());                        }                    } else if (role.isReversable()) {                        Role rev = role.getReverse();                        PersistentObject oldpo = (PersistentObject) old;                        PersistentObject po = (PersistentObject) value;                        PersistentObject me = retrieve(oid);                        if (rev.isCollection()) {                            if (oldpo != null) {                                addEvent(new RemoveEvent(Session.this,                                                         oldpo.getOID(), rev,                                                         me));                            }                            if (po != null) {                                addEvent(new AddEvent(Session.this,                                                      po.getOID(), rev, me));                            }                        } else {                            throw new IllegalStateException                                ("This case is just fucked up. " +                                 "I'll wait till it happens to deal with it.");                        }                    }                }