Package org.emftrace.metamodel.URNModel

Examples of org.emftrace.metamodel.URNModel.Concern


    }

    @Test
    public void testGetAttribute()
    {       
        Concern test = URNModelFactory.eINSTANCE.createConcern();
        test.setId("123");
        accessLayer.addElement(project, test);       
        assertNotNull(accessLayer.getAttribute(test, "Id"));
       
        assertNull(accessLayer.getAttribute(null, "creator"));
        assertNull(accessLayer.getAttribute(test, null));
View Full Code Here


    }

    @Test
    public void testGetElement()
    {       
        Concern test = URNModelFactory.eINSTANCE.createConcern();
        test.setId("123");
        accessLayer.addElement(project, test);       

        Concern test2 = (Concern)accessLayer.getElement(project, project.getModelElementId(test));

        assertSame(test, test2);
        assertNull(accessLayer.getElement(project, null));
        assertNull(accessLayer.getElement(null, project.getModelElementId(test)));
        assertNull(accessLayer.getElement(null, null));
View Full Code Here

    }
   
    @Test
    public void testGetAllElements()
    {
        Concern c1 = URNModelFactory.eINSTANCE.createConcern();
        Concern c2 = URNModelFactory.eINSTANCE.createConcern();
        Concern c3 = URNModelFactory.eINSTANCE.createConcern();
        accessLayer.addElement(project, c1);
        accessLayer.addElement(project, c2);
        accessLayer.addElement(project, c3);
       
        assertEquals(3, accessLayer.getAllElements(project).size());
View Full Code Here

    }

    @Test
    public void testRemoveElementProjectModelElement()
    {       
        Concern test = URNModelFactory.eINSTANCE.createConcern();
       
        assertEquals("Result", 0, project.getModelElements().size());
        accessLayer.addElement(project, test);
        assertEquals("Result", 1, project.getModelElements().size());
        accessLayer.removeElement(project, test);
View Full Code Here

     * plug-in registry is required
     */
    @Test
    public void testRemoveElementProjectModelElementId()
    {       
        Concern test = URNModelFactory.eINSTANCE.createConcern();
       
        assertEquals("Result", 0, project.getModelElements().size());
        accessLayer.addElement(project, test);
        assertEquals("Result", 1, project.getModelElements().size());
        accessLayer.removeElement(project, project.getModelElementId(test));
View Full Code Here

    }
   
    @Test
    public void testGetNameOfModel()
    {
        Concern test = URNModelFactory.eINSTANCE.createConcern();
        accessLayer.addElement(project, test);
       
        test.setName("HAL9000");
        assertEquals("HAL9000", accessLayer.getNameOfModel(test));
        assertNull(accessLayer.getNameOfModel(null));
    }
View Full Code Here

    }
   
    @Test
    public void testCountOccurrences()
    {
      Concern c1 = URNModelFactory.eINSTANCE.createConcern();
      Concern c2 = URNModelFactory.eINSTANCE.createConcern();
      Concern c3 = URNModelFactory.eINSTANCE.createConcern();
      Concern c4 = URNModelFactory.eINSTANCE.createConcern();
     
      List<EObject[]> tuples = new ArrayList<EObject[]>();
     
      tuples.add(new EObject[2]);
      tuples.get(0)[0] = c1;
View Full Code Here

      bc3.setSource("e1");
      bc1.setTarget("e2");
      bc2.setTarget("e2");
      bc3.setTarget("e2");
     
      Concern c1 = URNModelFactory.eINSTANCE.createConcern();
      Concern c2 = URNModelFactory.eINSTANCE.createConcern();
      Concern c3 = URNModelFactory.eINSTANCE.createConcern();
      Concern c4 = URNModelFactory.eINSTANCE.createConcern();
      Concern c5 = URNModelFactory.eINSTANCE.createConcern();
      Concern c6 = URNModelFactory.eINSTANCE.createConcern();
      Concern c7 = URNModelFactory.eINSTANCE.createConcern();
      Concern c8 = URNModelFactory.eINSTANCE.createConcern();
     
      List<EObject[]>       results = new ArrayList<EObject[]>();
      List<List<EObject[]>> tuples  = new ArrayList<List<EObject[]>>();
     
      tuples.add(new ArrayList<EObject[]>());
View Full Code Here

      e2.setAlias("e2");
     
      List<EObject[]> finalTuples   = new ArrayList<EObject[]>();
      List<EObject[]> currentTuples = new ArrayList<EObject[]>();
     
      Concern c1 = URNModelFactory.eINSTANCE.createConcern();
      Concern c2 = URNModelFactory.eINSTANCE.createConcern();
          
      bc1.setSource("e1");
      bc1.setTarget("e2");
      bc2.setSource("e2");     
      bc2.setTarget("e3");
View Full Code Here

      tuples.add(new ArrayList<EObject[]>()); // bc1
      tuples.add(new ArrayList<EObject[]>()); // bc2
      tuples.add(new ArrayList<EObject[]>()); // bc3
      tuples.add(new ArrayList<EObject[]>()); // bc4
     
      Concern c1 = URNModelFactory.eINSTANCE.createConcern();
      Concern c2 = URNModelFactory.eINSTANCE.createConcern();
      Concern c3 = URNModelFactory.eINSTANCE.createConcern();
      Concern c4 = URNModelFactory.eINSTANCE.createConcern();
      Concern c5 = URNModelFactory.eINSTANCE.createConcern();
      Concern c6 = URNModelFactory.eINSTANCE.createConcern();
      Concern c7 = URNModelFactory.eINSTANCE.createConcern();
      Concern c8 = URNModelFactory.eINSTANCE.createConcern();
     
      tuples.get(0).add(new EObject[2]); // bc1 tuple 1
      tuples.get(0).get(0)[0] = c1;
      tuples.get(0).get(0)[1] = c2;
      tuples.get(0).add(new EObject[2]); // bc1 tuple 2
View Full Code Here

TOP

Related Classes of org.emftrace.metamodel.URNModel.Concern

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.