Changeset 10788 in josm for trunk/src/org


Ignore:
Timestamp:
2016-08-12T12:17:25+02:00 (4 years ago)
Author:
simon04
Message:

Remove superfluous FilteredCollection

Not used by any plugin in SVN

Location:
trunk/src/org/openstreetmap/josm
Files:
1 deleted
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/Preferences.java

    r10657 r10788  
    6767import org.openstreetmap.josm.tools.CheckParameterUtil;
    6868import org.openstreetmap.josm.tools.ColorHelper;
    69 import org.openstreetmap.josm.tools.FilteredCollection;
    7069import org.openstreetmap.josm.tools.I18n;
    7170import org.openstreetmap.josm.tools.MultiMap;
     71import org.openstreetmap.josm.tools.SubclassFilteredCollection;
    7272import org.openstreetmap.josm.tools.Utils;
    7373import org.xml.sax.SAXException;
     
    507507    public synchronized void save() throws IOException {
    508508        save(getPreferenceFile(),
    509                 new FilteredCollection<>(settingsMap.entrySet(), NO_DEFAULT_SETTINGS_ENTRY), false);
     509                new SubclassFilteredCollection<>(settingsMap.entrySet(), NO_DEFAULT_SETTINGS_ENTRY), false);
    510510    }
    511511
  • trunk/src/org/openstreetmap/josm/data/osm/DataSet.java

    r10748 r10788  
    4747import org.openstreetmap.josm.gui.progress.ProgressMonitor;
    4848import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionManager;
    49 import org.openstreetmap.josm.tools.FilteredCollection;
    5049import org.openstreetmap.josm.tools.SubclassFilteredCollection;
    5150import org.openstreetmap.josm.tools.Utils;
     
    613612     */
    614613    public Collection<OsmPrimitive> getSelectedNodesAndWays() {
    615         return new FilteredCollection<>(getSelected(), primitive -> primitive instanceof Node || primitive instanceof Way);
     614        return new SubclassFilteredCollection<>(getSelected(), primitive -> primitive instanceof Node || primitive instanceof Way);
    616615    }
    617616
  • trunk/src/org/openstreetmap/josm/gui/dialogs/CommandStackDialog.java

    r10611 r10788  
    1212import java.util.ArrayList;
    1313import java.util.Arrays;
     14import java.util.Collection;
    1415import java.util.LinkedHashSet;
    1516import java.util.List;
     
    4546import org.openstreetmap.josm.gui.layer.OsmDataLayer.CommandQueueListener;
    4647import org.openstreetmap.josm.gui.widgets.PopupMenuLauncher;
    47 import org.openstreetmap.josm.tools.FilteredCollection;
    4848import org.openstreetmap.josm.tools.GBC;
    4949import org.openstreetmap.josm.tools.ImageProvider;
    5050import org.openstreetmap.josm.tools.InputMapUtils;
    5151import org.openstreetmap.josm.tools.Shortcut;
     52import org.openstreetmap.josm.tools.SubclassFilteredCollection;
    5253
    5354/**
     
    331332     * @return collection of affected primitives, onluy usable ones
    332333     */
    333     protected static FilteredCollection<? extends OsmPrimitive> getAffectedPrimitives(TreePath path) {
     334    protected static Collection<? extends OsmPrimitive> getAffectedPrimitives(TreePath path) {
    334335        PseudoCommand c = ((CommandListMutableTreeNode) path.getLastPathComponent()).getCommand();
    335336        final OsmDataLayer currentLayer = Main.getLayerManager().getEditLayer();
    336         return new FilteredCollection<>(
     337        return new SubclassFilteredCollection<>(
    337338                c.getParticipatingPrimitives(),
    338339                o -> {
  • trunk/src/org/openstreetmap/josm/gui/layer/OsmDataLayer.java

    r10716 r10788  
    9696import org.openstreetmap.josm.io.OsmImporter;
    9797import org.openstreetmap.josm.tools.CheckParameterUtil;
    98 import org.openstreetmap.josm.tools.FilteredCollection;
    9998import org.openstreetmap.josm.tools.GBC;
    10099import org.openstreetmap.josm.tools.ImageOverlay;
    101100import org.openstreetmap.josm.tools.ImageProvider;
    102101import org.openstreetmap.josm.tools.ImageProvider.ImageSizes;
     102import org.openstreetmap.josm.tools.SubclassFilteredCollection;
    103103import org.openstreetmap.josm.tools.date.DateUtils;
    104104
     
    425425
    426426    @Override public String getToolTipText() {
    427         int nodes = new FilteredCollection<>(data.getNodes(), p -> !p.isDeleted()).size();
    428         int ways = new FilteredCollection<>(data.getWays(), p -> !p.isDeleted()).size();
    429         int rels = new FilteredCollection<>(data.getRelations(), p -> !p.isDeleted()).size();
     427        int nodes = new SubclassFilteredCollection<>(data.getNodes(), p -> !p.isDeleted()).size();
     428        int ways = new SubclassFilteredCollection<>(data.getWays(), p -> !p.isDeleted()).size();
     429        int rels = new SubclassFilteredCollection<>(data.getRelations(), p -> !p.isDeleted()).size();
    430430
    431431        String tool = trn("{0} node", "{0} nodes", nodes, nodes)+", ";
Note: See TracChangeset for help on using the changeset viewer.