deletedObject.add(obj);
    public void delete(Object obj) throws ExcepcaoPersistencia    {        try        {            tx = odmg.currentTransaction();            tx.lock(obj, Transaction.WRITE);            db.deletePersistent(obj);            deletedObject.add(obj);            PersistenceBroker broker = ((HasBroker) tx).getBroker();            broker.removeFromCache(obj);        }        catch (ODMGRuntimeException ex)        {            throw new ExcepcaoPersistencia(ExcepcaoPersistencia.UPGRADE_LOCK,                    ex);        }    }