Ignore:
Timestamp:
2009-08-10T20:36:40+02:00 (13 years ago)
Author:
jttt
Message:

Replace some occurrences of RelationMember.member with getters

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/functional/org/openstreetmap/josm/gui/conflict/relation/RelationMemberMergerTest.java

    r1707 r1951  
    1010import org.openstreetmap.josm.data.osm.RelationMember;
    1111import org.openstreetmap.josm.data.osm.Way;
    12 import org.openstreetmap.josm.gui.conflict.nodes.NodeListMerger;
    13 import org.openstreetmap.josm.gui.conflict.nodes.NodeListMergerTest;
    1412
    1513public class RelationMemberMergerTest extends JFrame {
    16    
     14
    1715    private RelationMemberMerger merger;
    18    
     16
    1917    protected void populate() {
    2018        Relation r1 = new Relation();
    21         r1.members.add(new RelationMember("role1", new Node(1)));
    22         r1.members.add(new RelationMember("role2", new Way(2)));
    23         r1.members.add(new RelationMember("role3", new Relation(3)));
     19        r1.addMember(new RelationMember("role1", new Node(1)));
     20        r1.addMember(new RelationMember("role2", new Way(2)));
     21        r1.addMember(new RelationMember("role3", new Relation(3)));
    2422
    25        
     23
    2624        Relation r2 = new Relation();
    27         r2.members.add(new RelationMember("role1", new Node(1)));
    28         r2.members.add(new RelationMember("role2", new Way(2)));
    29         r2.members.add(new RelationMember("role3", new Relation(3)));
    30        
     25        r2.addMember(new RelationMember("role1", new Node(1)));
     26        r2.addMember(new RelationMember("role2", new Way(2)));
     27        r2.addMember(new RelationMember("role3", new Relation(3)));
     28
    3129        merger.populate(r1, r2);
    3230
    3331    }
    34    
     32
    3533    protected void build() {
    3634        merger = new RelationMemberMerger();
     
    3836        getContentPane().add(merger, BorderLayout.CENTER);
    3937    }
    40    
     38
    4139    public RelationMemberMergerTest() {
    4240        build();
    4341        populate();
    4442    }
    45    
     43
    4644    static public void main(String args[]) {
    4745        RelationMemberMergerTest test = new RelationMemberMergerTest();
Note: See TracChangeset for help on using the changeset viewer.