示例#1
0
 public void RemoveRelation(UmlRelation umlRelation)
 {
     if (relations.Contains(umlRelation))
     {
         RemoveLink(umlRelation);
         Relations.Remove(umlRelation);
     }
 }
示例#2
0
 public void AddRelation(UmlRelation umlRelation)
 {
     if (!relations.Contains(umlRelation))
     {
         AddLink(umlRelation);
         relations.Add(umlRelation);
     }
 }
示例#3
0
        public UmlRelation GetOrCreateImplementsInterfaceRelation(bool fromDiagram, UmlClass startClass, UmlClass endClass)
        {
            UmlRelation rel = GetRelation <UmlImplementsInterfaceRelation>(startClass, endClass);

            if (rel == null)
            {
                rel = new UmlImplementsInterfaceRelation(startClass, endClass);
                AddRelation(rel, fromDiagram);
            }
            return(rel);
        }
示例#4
0
 public void RemoveRelation(UmlRelation umlRelation, bool notifyObservers)
 {
     if (relations.Contains(umlRelation))
     {
         RemoveLink(umlRelation);
         relations.Remove(umlRelation);
         if (notifyObservers)
         {
             OnModified();
         }
     }
 }
示例#5
0
 public void AddRelation(UmlRelation umlRelation, bool notifyObservers)
 {
     if (!relations.Contains(umlRelation))
     {
         AddLink(umlRelation);
         relations.Add(umlRelation);
         if (notifyObservers)
         {
             OnModified();
         }
     }
 }