Changeset 3801 in josm for trunk/src/org/openstreetmap/josm/data
- Timestamp:
- 2011-01-22T14:36:36+01:00 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/osm/DataSet.java
r3782 r3801 34 34 import org.openstreetmap.josm.data.osm.event.WayNodesChangedEvent; 35 35 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionManager; 36 import org.openstreetmap.josm.tools.FilteredCollection; 36 37 import org.openstreetmap.josm.tools.Predicate; 38 import org.openstreetmap.josm.tools.SubclassFilteredCollection; 37 39 38 40 /** … … 174 176 175 177 private <T extends OsmPrimitive> Collection<T> getPrimitives(Predicate<OsmPrimitive> predicate) { 176 return new DatasetCollection<T>(allPrimitives, predicate);178 return new SubclassFilteredCollection<OsmPrimitive, T>(allPrimitives, predicate); 177 179 } 178 180 … … 386 388 387 389 public Collection<OsmPrimitive> getSelectedNodesAndWays() { 388 return new DatasetCollection<OsmPrimitive>(getSelected(), new Predicate<OsmPrimitive>() {390 return new FilteredCollection<OsmPrimitive>(getSelected(), new Predicate<OsmPrimitive>() { 389 391 @Override 390 392 public boolean evaluate(OsmPrimitive primitive) { … … 415 417 */ 416 418 public Collection<Node> getSelectedNodes() { 417 return new DatasetCollection<Node>(getSelected(), OsmPrimitive.nodePredicate);419 return new SubclassFilteredCollection<OsmPrimitive, Node>(getSelected(), OsmPrimitive.nodePredicate); 418 420 } 419 421 … … 422 424 */ 423 425 public Collection<Way> getSelectedWays() { 424 return new DatasetCollection<Way>(getSelected(), OsmPrimitive.wayPredicate);426 return new SubclassFilteredCollection<OsmPrimitive, Way>(getSelected(), OsmPrimitive.wayPredicate); 425 427 } 426 428 … … 429 431 */ 430 432 public Collection<Relation> getSelectedRelations() { 431 return new DatasetCollection<Relation>(getSelected(), OsmPrimitive.relationPredicate);433 return new SubclassFilteredCollection<OsmPrimitive, Relation>(getSelected(), OsmPrimitive.relationPredicate); 432 434 } 433 435
Note:
See TracChangeset
for help on using the changeset viewer.