コード例 #1
0
 public Association createAssociation(BaseElement source, BaseElement target) {
   BaseElement e = null;
   if (getParticipant(source) != null) {
     e = source;
   } else if (getParticipant(target) != null) {
     e = target;
   } else {
     e = getInternalParticipant();
   }
   Association association = FACTORY.createAssociation();
   addArtifact(e, association);
   //		association.setId(EcoreUtil.generateUUID());
   ModelUtil.setID(association, resource);
   association.setSourceRef(source);
   association.setTargetRef(target);
   return association;
 }