Changeset 1933 in josm for trunk


Ignore:
Timestamp:
2009-08-08T14:09:36+02:00 (15 years ago)
Author:
Gubaer
Message:

Made OsmPrimitive::getName() abstract, implemented getName() on Changeset

Location:
trunk/src/org/openstreetmap/josm/data/osm
Files:
2 edited

Legend:

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

    r1677 r1933  
    33
    44import org.openstreetmap.josm.data.osm.visitor.Visitor;
     5import static org.openstreetmap.josm.tools.I18n.tr;
    56
    67/**
     
    2223    public String start_timestamp = null;
    2324
     25    @Override
    2426    public void visit(Visitor v) {
    2527        v.visit(this);
    2628    }
    2729
    28     public int compareTo(OsmPrimitive arg0) {
    29         if (arg0 instanceof Changeset) return Long.valueOf(id).compareTo(arg0.id);
     30    public int compareTo(OsmPrimitive other) {
     31        if (other instanceof Changeset) return Long.valueOf(id).compareTo(other.id);
    3032        return 1;
    3133    }
     34
     35    @Override
     36    public String getName() {
     37        return tr("Changeset {0}",id);
     38    }
    3239}
  • trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java

    r1932 r1933  
    359359    }
    360360
    361 
    362 
    363 
    364 
    365 
    366     public String getName() {
    367         return null;
    368     }
     361    /**
     362     * Replies the name of this primitive.
     363     *
     364     * @return the name of this primitive
     365     */
     366    public abstract String getName();
    369367
    370368    /**
Note: See TracChangeset for help on using the changeset viewer.