Пример #1
0
        protected override bool ApplyPropertyValues(ChoPlugInBuilderProperty plugInBuilderProperty, string propertyName)
        {
            if (plugInBuilderProperty == null)
            {
                return(false);
            }
            base.ApplyPropertyValues(plugInBuilderProperty, propertyName);

            ChoJavaScriptPlugInBuilderProperty o = plugInBuilderProperty as ChoJavaScriptPlugInBuilderProperty;

            if (o == null)
            {
                return(false);
            }

            if (propertyName == "Script")
            {
                Script = new ChoCDATA(o.Script);
            }
            else if (propertyName == "Arguments")
            {
                Arguments = new ChoCDATA(o.Arguments);
            }
            else if (propertyName == "WorkingDirectory")
            {
                WorkingDirectory = o.WorkingDirectory;
            }
            else
            {
                return(false);
            }

            return(true);
        }
Пример #2
0
        protected override void InitPlugInBuilderProperty(ChoPlugInBuilderProperty plugInBuilderProperty)
        {
            if (plugInBuilderProperty == null)
            {
                return;
            }

            base.InitPlugInBuilderProperty(plugInBuilderProperty);

            ChoJavaScriptPlugInBuilderProperty o = plugInBuilderProperty as ChoJavaScriptPlugInBuilderProperty;

            if (o == null)
            {
                return;
            }

            o.Script           = Script.GetValue();
            o.Arguments        = Arguments.GetValue();
            o.WorkingDirectory = WorkingDirectory;
        }