clone() public method

public clone ( ) : Compartment
return Compartment
Ejemplo n.º 1
0
 public void test_Compartment_clone()
 {
     Compartment o1 = new Compartment(2,4);
       o1.setId("c");
       o1.setOutside("c2");
       assertTrue( o1.getId() ==  "c" );
       assertTrue( o1.getOutside() ==  "c2" );
       Compartment o2 = o1.clone();
       assertTrue( o2.getId() ==  "c" );
       assertTrue( o2.getOutside() ==  "c2" );
       assertTrue( o2.getParentSBMLObject() == o1.getParentSBMLObject() );
       o2 = null;
       o1 = null;
 }