@Test public void testDispose() { final EventList<String> source = new BasicEventList<>(); final DisposableMap<String, String> eventMap = GlazedLists.syncEventListToMap(source, new FirstLetterFunction()); source.add("Bluto"); source.add("Popeye"); source.add("Olive"); assertEquals(3, eventMap.size()); eventMap.dispose(); }
@Override public void dispose() { valueList.removeListEventListener(eventListener); keySet = null; entrySet = null; keyList.clear(); delegate.clear(); }
FunctionListMap implements DisposableMap<K, V> { @Override public void dispose() { valueList.removeListEventListener(eventListener); keySet = null; entrySet = null; keyList.clear(); delegate.clear(); } }
FunctionListMap implements DisposableMap<K, V> { @Override public void dispose() { valueList.removeListEventListener(eventListener); keySet = null; entrySet = null; keyList.clear(); delegate.clear(); } FunctionListMap(EventList<V> source, FunctionList.Function<V, K> keyFunction); }
FunctionListMap implements DisposableMap<K, V> { @Override public void dispose() { valueList.removeListEventListener(eventListener); keySet = null; entrySet = null; keyList.clear(); delegate.clear(); } FunctionListMap(EventList<V> source, FunctionList.Function<V, K> keyFunction); @Override void dispose(); @Override int size(); @Override boolean isEmpty(); @Override boolean containsKey(Object key); @Override boolean containsValue(Object value); @Override V get(Object key); @Override V put(K key, V value); @Override void putAll(Map<? extends K, ? extends V> m); @Override void clear(); @Override V remove(Object key); @Override Collection<V> values(); @Override Set<K> keySet(); @Override Set<Entry<K, V>> entrySet(); @Override void forEach(BiConsumer<? super K, ? super V> action); @Override boolean equals(Object o); @Override int hashCode(); }
FunctionListMap implements DisposableMap<K, V> { @Override public void dispose() { valueList.removeListEventListener(eventListener); keySet = null; entrySet = null; keyList.clear(); delegate.clear(); } FunctionListMap(EventList<V> source, FunctionList.Function<V, K> keyFunction); @Override void dispose(); @Override int size(); @Override boolean isEmpty(); @Override boolean containsKey(Object key); @Override boolean containsValue(Object value); @Override V get(Object key); @Override V put(K key, V value); @Override void putAll(Map<? extends K, ? extends V> m); @Override void clear(); @Override V remove(Object key); @Override Collection<V> values(); @Override Set<K> keySet(); @Override Set<Entry<K, V>> entrySet(); @Override void forEach(BiConsumer<? super K, ? super V> action); @Override boolean equals(Object o); @Override int hashCode();  }