public BusShape(IModel model, CommandReference reference, IFlyweightShape <BusShape> fly)
            : base(model)
        {
            this.sysRef = reference;

            busConnector        = new YttriumConnector(Model, ConnectorType.BusConnector); //new Point((int)(Rectangle.Left + Rectangle.Width / 2), Rectangle.Bottom),
            busConnector.Name   = "Bus";
            busConnector.Parent = this;
            Connectors.Add(busConnector);

            AssignFly(fly);
        }
        public SignalShape(IModel model, CommandReference reference, IFlyweightShape <SignalShape> fly)
            : base(model)
        {
            this.sysRef = reference;

            outConnector        = new YttriumConnector(Model, ConnectorType.SignalOutputConnector);
            outConnector.Name   = "Output";
            outConnector.Parent = this;
            Connectors.Add(outConnector);

            inConnector        = new YttriumConnector(Model, ConnectorType.SignalInputConnector);
            inConnector.Name   = "Input";
            inConnector.Parent = this;
            Connectors.Add(inConnector);

            AssignFly(fly);
        }
 private void SyncConnectors(ICollection <IConnector> connectors, IModel model, int count, List <YttriumConnector> list, string prefix, ConnectorType type)
 {
     if (count > list.Count)
     {
         for (int i = list.Count; i < count; i++)
         {
             YttriumConnector c = new YttriumConnector(model, type);
             c.Name   = prefix + i.ToString();
             c.Parent = this;
             list.Add(c);
             connectors.Add(c);
         }
     }
     else if (count < list.Count)
     {
         for (int i = list.Count - 1; i > count; i--)
         {
             YttriumConnector c = list[i];
             connectors.Remove(c);
             list.RemoveAt(i);
         }
     }
 }