@Test public void testClear() throws Exception { assertTrue("The set should be initialized empty.", set.isEmpty()); set.clear(); assertTrue("Clear should have no effect on an empty set.", set.isEmpty()); fillSet(10, set); assertFalse("The set should no longer be empty.", set.isEmpty()); set.clear(); assertTrue("The set should be empty after clear.", set.isEmpty()); }
@Override public void clear() { items.clear(); }
PersistentSet implements Set<E> { @Override public void clear() { items.clear(); } }
PersistentSet implements Set<E> { @Override public void clear() { items.clear(); } PersistentSet(org.onosproject.store.service.Serializer serializer, DB database, String name); }
PersistentSet implements Set<E> { @Override public void clear() { items.clear(); } PersistentSet(org.onosproject.store.service.Serializer serializer, DB database, String name); void readInto(Set<E> items); @Override int size(); @Override boolean isEmpty(); @Override boolean contains(Object o); @Override Iterator<E> iterator(); @Override Object[] toArray(); @Override T[] toArray(T[] a); @Override boolean add(E item); @Override boolean remove(Object o); @Override boolean containsAll(Collection<?> c); @Override boolean addAll(Collection<? extends E> c); @Override boolean retainAll(Collection<?> c); @Override boolean removeAll(Collection<?> c); @Override void clear(); @Override boolean equals(Object set); @Override int hashCode(); }
PersistentSet implements Set<E> { @Override public void clear() { items.clear(); } PersistentSet(org.onosproject.store.service.Serializer serializer, DB database, String name); void readInto(Set<E> items); @Override int size(); @Override boolean isEmpty(); @Override boolean contains(Object o); @Override Iterator<E> iterator(); @Override Object[] toArray(); @Override T[] toArray(T[] a); @Override boolean add(E item); @Override boolean remove(Object o); @Override boolean containsAll(Collection<?> c); @Override boolean addAll(Collection<? extends E> c); @Override boolean retainAll(Collection<?> c); @Override boolean removeAll(Collection<?> c); @Override void clear(); @Override boolean equals(Object set); @Override int hashCode();  }