public override StepInput[] GetProperties(IOrchestrationComponent component)
 {
     return(new StepInput[0]);
 }
 public override StepOutcome[] GetOutcomes(IOrchestrationComponent component)
 {
     return(null);
 }
 public override StepOutcome[] GetOutcomes(IOrchestrationComponent component)
 {
     // Linked model outputs will need to be recreated to work well
     // so no need to worry about the outcomes from the old engine here.
     return(new StepOutcome[0]);
 }
Beispiel #4
0
 private StepInput[] ConvertStepPropertiesDefault(IOrchestrationComponent component)
 {
     return(new StepInput[0]);
 }
Beispiel #5
0
        private ConvertedStep CreateFlowStepFromComponent(string projectName, IOrchestrationComponent component, string modelName)
        {
            Report("Transforming Component {0}", component.Name);

            if (component.GetType().FullName == typeof(FormBuilderComponent).FullName)
            {
                ConvertedForm form = FormBuilderConvertor.GetForm(component);

                if (string.IsNullOrEmpty(modelName))
                {
                    form.Tags = new string[] { "Root" };
                }

                else
                {
                    form.Tags = new string[] { modelName };
                }

                form.FormId = component.Id;

                // Add this form to the converted results that we are building.
                allForms.Add(form);

                // And now create the ConvertedStep to represent the form wrapper step on the
                // decisions side.
                ConvertedStep forWrapperStep = new ConvertedStep();
                forWrapperStep.StepName = component.Name;
                forWrapperStep.X        = (int)component.Location.X;
                forWrapperStep.Y        = (int)component.Location.Y;
                forWrapperStep.UniqueStepIdForConnections = component.Id;

                forWrapperStep.FullTypeName = "FormWrapperStep";

                return(forWrapperStep);
            }

            ConvertedStep result = new ConvertedStep();

            //build up dictionary of steps and count just so we can know how many are in this flow
            if (dictAllStepsCount.ContainsKey(component.GetType().Name))
            {
                dictAllStepsCount[component.GetType().Name] = dictAllStepsCount[component.GetType().Name] + 1;
            }
            else
            {
                dictAllStepsCount.Add(component.GetType().Name, 1);
            }

            List <string> baseTypeNamesToSkip = new List <string>();

            baseTypeNamesToSkip.Add("AbstractSQLSinglePathComponent");
            //baseTypeNamesToSkip.Add("AbstractSinglePathProcessComponent");
            //baseTypeNamesToSkip.Add("AbstractConnectionStringMultiPathComponent");

            List <string> typeNamesToSkip = new List <string>();

            typeNamesToSkip.Add("LogicBase.Components.Default.Process.MultiPathEmbeddedModelComponent");
            typeNamesToSkip.Add("LogicBase.Components.Default.IO.ReadFile");
            typeNamesToSkip.Add("LogicBase.Components.Default.IterateTextFileLines");
            typeNamesToSkip.Add("LogicBase.Components.Office2003.Word2003ModelComponent");
            typeNamesToSkip.Add("LogicBase.Components.Default.IO.CreateTextFile");
            typeNamesToSkip.Add("LogicBase.Components.Default.Process.SubtractValues");

            List <string> assembliesToSkip = new List <string>();

            assembliesToSkip.Add("Wrap Up 2 Integration.dll");
            assembliesToSkip.Add("Wrap Up Client Side Integration.dll");

            if (baseTypeNamesToSkip.Contains(component.GetType().BaseType.Name) || typeNamesToSkip.Contains(component.GetType().FullName) || assembliesToSkip.Contains(component.GetType().Assembly.ManifestModule.Name))
            {
                result.StepName = component.Name;
                result.UniqueStepIdForConnections = component.Id;
                result.InputData      = new StepInput[0];
                result.OutcomeData    = new StepOutcome[0];
                result.FullTypeName   = "No type";
                result.StepProperties = new StepInput[0];
                result.X = (int)component.Location.X;
                result.Y = (int)component.Location.Y;

                return(result);
            }

            result.UniqueStepIdForConnections = component.Id;

            result.FullTypeName = component.GetType().FullName;
            result.StepName     = component.Name;
            result.X            = (int)component.Location.X;
            result.Y            = (int)component.Location.Y;

            if (ConverterFor.ContainsKey(component.GetType()))
            {
                result.InputData      = ConverterFor[component.GetType()].GetInputs(component);
                result.StepProperties = ConverterFor[component.GetType()].GetProperties(component);
                result.OutcomeData    = ConverterFor[component.GetType()].GetOutcomes(component);
            }
            else
            {
                result.InputData      = ConvertInputDataDefault(component);
                result.StepProperties = ConvertStepPropertiesDefault(component);
                result.OutcomeData    = ConvertOutDataDefault(component);
                // Setup common properties
            }
            return(result);
        }
 public abstract StepInput[] GetProperties(IOrchestrationComponent component);
 public abstract StepOutcome[] GetOutcomes(IOrchestrationComponent component);
 public abstract StepInput[] GetInputs(IOrchestrationComponent component);