@Test public void testSeparatorIsThreadSafe() throws InterruptedException { final BasicEventList<String> source = new BasicEventList<>(); source.addAll(GlazedListsTests.stringToList("AABBBCCCCDDDDEFGHHHH")); final SeparatorList<String> separatorList = new SeparatorList<>(source, GlazedLists.comparableComparator(), 0, Integer.MAX_VALUE); ListConsistencyListener listConsistencyListener = ListConsistencyListener.install(separatorList); listConsistencyListener.setPreviousElementTracked(false); assertEqualsIgnoreSeparators(source, separatorList, GlazedLists.comparableComparator()); SeparatorList.Separator separator = (SeparatorList.Separator)(Object)separatorList.get(0); assertEquals("A", separator.first()); assertEquals(2, separator.size()); source.clear(); assertEquals(null, separator.first()); assertEquals(0, separator.size()); }
@Override public int size() { return collapsedElements.colourSize(Barcode.BLACK); }
SeparatorList extends TransformedList<E, E> { @Override public int size() { return collapsedElements.colourSize(Barcode.BLACK); } }
SeparatorList extends TransformedList<E, E> { @Override public int size() { return collapsedElements.colourSize(Barcode.BLACK); } SeparatorList(EventList<E> source, Comparator<? super E> comparator, int minimumSizeForSeparator, int defaultLimit); }
SeparatorList extends TransformedList<E, E> { @Override public int size() { return collapsedElements.colourSize(Barcode.BLACK); } SeparatorList(EventList<E> source, Comparator<? super E> comparator, int minimumSizeForSeparator, int defaultLimit); @Override int size(); void setComparator(Comparator<E> comparator); @Override void listChanged(ListEvent<E> listChanges); @Override void dispose(); }
SeparatorList extends TransformedList<E, E> { @Override public int size() { return collapsedElements.colourSize(Barcode.BLACK); } SeparatorList(EventList<E> source, Comparator<? super E> comparator, int minimumSizeForSeparator, int defaultLimit); @Override int size(); void setComparator(Comparator<E> comparator); @Override void listChanged(ListEvent<E> listChanges); @Override void dispose();  }