@Test public void add() { assertTrue(propagationByResource.add(ResourceOperation.CREATE, KEY)); assertTrue(propagationByResource.add(ResourceOperation.UPDATE, KEY)); assertTrue(propagationByResource.add(ResourceOperation.DELETE, KEY)); assertFalse(propagationByResource.add(ResourceOperation.NONE, KEY)); }
public final boolean add(final ResourceOperation type, final T key) { Set<T> set; switch (type) { case CREATE: set = toBeCreated; break; case UPDATE: set = toBeUpdated; break; case DELETE: default: set = toBeDeleted; break; } return set.add(key); }
PropagationByResource implements Serializable { public final boolean add(final ResourceOperation type, final T key) { Set<T> set; switch (type) { case CREATE: set = toBeCreated; break; case UPDATE: set = toBeUpdated; break; case DELETE: default: set = toBeDeleted; break; } return set.add(key); } }
PropagationByResource implements Serializable { public final boolean add(final ResourceOperation type, final T key) { Set<T> set; switch (type) { case CREATE: set = toBeCreated; break; case UPDATE: set = toBeUpdated; break; case DELETE: default: set = toBeDeleted; break; } return set.add(key); } PropagationByResource(); }
PropagationByResource implements Serializable { public final boolean add(final ResourceOperation type, final T key) { Set<T> set; switch (type) { case CREATE: set = toBeCreated; break; case UPDATE: set = toBeUpdated; break; case DELETE: default: set = toBeDeleted; break; } return set.add(key); } PropagationByResource(); final void purge(); final boolean add(final ResourceOperation type, final T key); boolean addAll(final ResourceOperation type, final Collection<T> keys); final boolean remove(final ResourceOperation type, final T key); boolean removeAll(final ResourceOperation type, final Set<T> keys); boolean removeAll(final Collection<T> keys); boolean retainAll(final Collection<T> keys); boolean contains(final ResourceOperation type, final T key); boolean contains(final T key); final Set<T> get(final ResourceOperation type); Map<T, ResourceOperation> asMap(); final void set(final ResourceOperation type, final Collection<T> keys); final void merge(final PropagationByResource<T> propByRes); void clear(); final boolean isEmpty(); Map<String, String> getOldConnObjectKeys(); String getOldConnObjectKey(final String resourceKey); void addOldConnObjectKey(final String resourceKey, final String oldConnObjectKey); @Override String toString(); }
PropagationByResource implements Serializable { public final boolean add(final ResourceOperation type, final T key) { Set<T> set; switch (type) { case CREATE: set = toBeCreated; break; case UPDATE: set = toBeUpdated; break; case DELETE: default: set = toBeDeleted; break; } return set.add(key); } PropagationByResource(); final void purge(); final boolean add(final ResourceOperation type, final T key); boolean addAll(final ResourceOperation type, final Collection<T> keys); final boolean remove(final ResourceOperation type, final T key); boolean removeAll(final ResourceOperation type, final Set<T> keys); boolean removeAll(final Collection<T> keys); boolean retainAll(final Collection<T> keys); boolean contains(final ResourceOperation type, final T key); boolean contains(final T key); final Set<T> get(final ResourceOperation type); Map<T, ResourceOperation> asMap(); final void set(final ResourceOperation type, final Collection<T> keys); final void merge(final PropagationByResource<T> propByRes); void clear(); final boolean isEmpty(); Map<String, String> getOldConnObjectKeys(); String getOldConnObjectKey(final String resourceKey); void addOldConnObjectKey(final String resourceKey, final String oldConnObjectKey); @Override String toString();  }