Package org.apache.cayenne.map.event

Examples of org.apache.cayenne.map.event.DataMapEvent


    }

    public void removeDataMap(DataDomain domain, DataMap map) {
        ProjectController mediator = getProjectController();

        DataMapEvent e = new DataMapEvent(Application.getFrame(), map, MapEvent.REMOVE);
        e.setDomain(domain);

        domain.removeMap(map.getName());
        mediator.fireDataMapEvent(e);
    }
View Full Code Here


public class DataMapEventTest extends TestCase {

   public void testConstructor1() throws Exception {
      Object src = new Object();
      DataMap d = new DataMap("abc");
      DataMapEvent e = new DataMapEvent(src, d);
     
      assertSame(src, e.getSource());
      assertSame(d, e.getDataMap());
    }
View Full Code Here

    }
   
    public void testConstructor2() throws Exception  {
      Object src = new Object();
      DataMap d = new DataMap("abc");
      DataMapEvent e = new DataMapEvent(src, d, "oldname");
     
      assertSame(src, e.getSource());
      assertSame(d, e.getDataMap());
      assertEquals("oldname", e.getOldName());
    }
View Full Code Here

    }
   
    public void testDataMap() throws Exception  {
      Object src = new Object();
         DataMap d = new DataMap("abc");
      DataMapEvent e = new DataMapEvent(src, null);
     
      e.setDataMap(d);
      assertSame(d, e.getDataMap());
    }
View Full Code Here

            cleanup();

            // fire up events
            loadStatusNote = "Updating view...";
            if (mediator.getCurrentDataMap() != null) {
                mediator.fireDataMapEvent(new DataMapEvent(
                        Application.getFrame(),
                        dataMap,
                        MapEvent.CHANGE));
                mediator.fireDataMapDisplayEvent(new DataMapDisplayEvent(
                        Application.getFrame(),
View Full Code Here

TOP

Related Classes of org.apache.cayenne.map.event.DataMapEvent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.