Beispiel #1
0
        /*************************************/

        public virtual bool RemoveInput(string name)
        {
            if (name == null)
            {
                return(false);
            }

            ParamInfo match = InputParams.Find(x => x.Name == name);

            if (match != null)
            {
                match.IsSelected = false;
            }

            return(true);
        }
Beispiel #2
0
        /*************************************/
        /**** Input Methods               ****/
        /*************************************/

        public virtual bool AddInput(int index, string name, Type type = null)
        {
            if (name == null || index < 0)
            {
                return(false);
            }

            ParamInfo match = InputParams.Find(x => x.Name == name);

            if (match != null)
            {
                match.IsSelected = true;
            }
            else
            {
                ParamInfo param = Engine.UI.Create.ParamInfo(name, type);
                InputParams.Insert(index, param);
                m_CompiledGetters.Insert(index, Engine.UI.Create.InputAccessor(m_DataAccessor.GetType(), param.DataType));
            }

            return(true);
        }
Beispiel #3
0
        /*************************************/

        public virtual bool CanRemoveInput(string name)
        {
            ParamInfo match = InputParams.Find(x => x.Name == name);

            return(match != null && !match.IsRequired);
        }