@Override public void update(long id, int activeSession, Date updateTime, byte[] sessionDetails) { ConsoleProxyVO ub = createForUpdate(); ub.setActiveSession(activeSession); ub.setLastUpdateTime(updateTime); ub.setSessionDetails(sessionDetails); update(id, ub); }
@Override public boolean remove(Long id) { TransactionLegacy txn = TransactionLegacy.currentTxn(); txn.start(); ConsoleProxyVO proxy = createForUpdate(); proxy.setPublicIpAddress(null); proxy.setPrivateIpAddress(null); UpdateBuilder ub = getUpdateBuilder(proxy); ub.set(proxy, "state", State.Destroyed); ub.set(proxy, "privateIpAddress", null); update(id, ub, proxy); boolean result = super.remove(id); txn.commit(); return result; }