Exemple #1
0
        private void ExpandInstances()
        {
            var group = this.Node as WorkflowNodeGroup;

            if (group == null)
            {
                return;
            }

            if (group.Nodes == null)
            {
                return;
            }

            foreach (WorkflowNode node in group.Nodes)
            {
                var child = new WorkflowNodeInstance()
                {
                    Node   = node,
                    Root   = this.Root,
                    Parent = this
                };

                child.ExpandInstances();
                this.Children.Add(child);
            }
        }
Exemple #2
0
        public static WorkflowNodeInstance FromConfiguration(WorkflowServiceConfiguration configuration)
        {
            var nodeInstance = new WorkflowNodeInstance()
            {
                Node = configuration.Workflow,
            };

            nodeInstance.Root = nodeInstance;

            nodeInstance.ExpandInstances();
            return(nodeInstance);
        }