Ejemplo n.º 1
0
        public void OnImportsSatisfied()
        {
            Pd = new PinDictionary(FIOFactory);
            foreach (var pin in FPluginHost.GetPins())
            {
                if (pin.Name != "Descriptive Name")
                {
                    continue;
                }
                pin.SetSlice(0, "");
                break;
            }

            _pg = new ConfigurableTypePinGroup(FPluginHost, FIOFactory, Hde.MainLoop, "Input", 100);
            _pg.OnTypeChangeEnd += (sender, args) =>
            {
                _typeChanged = true;

                foreach (var pin in FPluginHost.GetPins())
                {
                    if (pin.Name != "Descriptive Name")
                    {
                        continue;
                    }
                    pin.SetSlice(0, "");
                    break;
                }
                Pd.RemoveAllInput();
                IsMemberEnumerable.Clear();

                foreach (var pin in FPluginHost.GetPins())
                {
                    if (pin.Name != "Descriptive Name")
                    {
                        continue;
                    }
                    pin.SetSlice(0, _pg.GroupType.GetCSharpName());
                    break;
                }

                foreach (var field in _pg.GroupType.GetFields())
                {
                    AddMemberPin(field);
                }
                foreach (var prop in _pg.GroupType.GetProperties())
                {
                    AddMemberPin(prop);
                }

                if (_pgready)
                {
                    return;
                }
                _pgready = true;
                _input   = _pg.AddInput(new InputAttribute("Input"));
            };
        }
Ejemplo n.º 2
0
        /// <summary>
        /// This method is not useful yet. It's purpose is to sync all input pins automatically.
        /// There is no easy way to find all Pins of a node that allows for syncing, IPin does not have this functionality
        /// </summary>
        protected virtual void StartEvaluation()
        {
            //          Sync all input pins.

            foreach (var p in FHost.GetPins())
            {
//                FLogger.Log(LogType.Message, p.ToString());
            }
        }
Ejemplo n.º 3
0
 protected override void PreInitialize()
 {
     ConfigPinCopy = FType;
     FRefType      = new GenericInput(FPluginHost, new InputAttribute("Reference Type")
     {
         Order = 1
     });
     Pd = new PinDictionary(FIOFactory);
     foreach (var pin in FPluginHost.GetPins())
     {
         if (pin.Name != "Descriptive Name")
         {
             continue;
         }
         pin.SetSlice(0, "");
         break;
     }
 }