public boolean removeComponent(Component comp, boolean recycleAllowed) { final String uuid = comp.getUuid(); if (_comps.remove(uuid) == null || !recycleAllowed || recycleUuidDisabled() || (comp instanceof StubComponent)) //Bug ZK-1452: don't need to recycle StubComponent's uuid since it's never reset return false; //not recycled //Bug 3002611: don't recycle UUID if RawId, since addUuidChanged will //cause AuRemove to be sent if (comp instanceof RawId && (!ComponentsCtrl.isAutoUuid(uuid) || ((WebAppCtrl) _wapp).getIdGenerator() != null)) return false; //not recycled final int execId = getExecId(); RecycleInfo ri = null; if (_uuidRecycle == null) { _uuidRecycle = new LinkedList<RecycleInfo>(); } else { for (RecycleInfo r : _uuidRecycle) if (r.execId == execId) { ri = r; //found break; } } if (ri == null) _uuidRecycle.add(ri = new RecycleInfo(execId)); ri.uuids.add(uuid); return true; //recycled }