Ignore:
Timestamp:
2009-07-27T21:09:44+02:00 (15 years ago)
Author:
jttt
Message:

Way refactoring - added method that will in future replace public field nodes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/actions/search/SearchCompiler.java

    r1843 r1862  
    375375        public NodeCount(int count) {this.count = count;}
    376376        @Override public boolean match(OsmPrimitive osm) {
    377             return osm instanceof Way && ((Way) osm).nodes.size() == count;
     377            return osm instanceof Way && ((Way) osm).getNodesCount() == count;
    378378        }
    379379        @Override public String toString() {return "nodes="+count;}
     
    394394        @Override public boolean match(OsmPrimitive osm) {
    395395            if(!(osm instanceof Way)) return false;
    396             int size = ((Way)osm).nodes.size();
     396            int size = ((Way)osm).getNodesCount();
    397397            return (size >= minCount) && (size <= maxCount);
    398398        }
     
    441441
    442442            if (osm instanceof Way) {
    443                 for (Node n : ((Way)osm).nodes) {
     443                for (Node n : ((Way)osm).getNodes()) {
    444444                    isParent |= child.match(n);
    445445                }
Note: See TracChangeset for help on using the changeset viewer.