示例#1
0
 public List <Path> Generete(IPrimitiveLink startPrimitive)
 {
     foreach (var link in startPrimitive.GetNextLinks())
     {
         GeneratePath(link, new Path());
     }
     return(this.pathes);
 }
示例#2
0
        public static Link Create(IPrimitiveLink outPrimitive, IPrimitiveLink inPrimitive)
        {
            Link l = new Link();

            l.ComingPrimitive   = inPrimitive;
            l.OutgoingPrimitive = outPrimitive;
            if (l.Validate())
            {
                l.Description = l.ToString();
                Owner.Instance.AddObject(l);
                Owner.Instance.RefreshPathes();
                return(l);
            }
            else
            {
                return(null);
            }
        }