public override InitialSessionStateEntry Clone()
        {
            SessionStateWorkflowEntry entry = new SessionStateWorkflowEntry(base.Name, this._definition, this._options, base.Visibility, this._workflow, this._helpFile);

            entry.SetModule(base.Module);
            return(entry);
        }
Esempio n. 2
0
        internal void AddSessionStateEntry(InitialSessionState initialSessionState, SessionStateWorkflowEntry entry)
        {
            var converterInstance = Utils.GetAstToWorkflowConverterAndEnsureWorkflowModuleLoaded(null);

            var workflowInfo = entry.WorkflowInfo ??
                               converterInstance.CompileWorkflow(entry.Name, entry.Definition, initialSessionState);

            WorkflowInfo wf = new WorkflowInfo(workflowInfo);

            wf = this.SetWorkflowRaw(wf, CommandOrigin.Internal);
            wf.Visibility = entry.Visibility;
            wf.Module = entry.Module;
        }
Esempio n. 3
0
 public override InitialSessionStateEntry Clone()
 {
     SessionStateWorkflowEntry entry = new SessionStateWorkflowEntry(base.Name, this._definition, this._options, base.Visibility, this._workflow, this._helpFile);
     entry.SetModule(base.Module);
     return entry;
 }
Esempio n. 4
0
 internal void AddSessionStateEntry(InitialSessionState initialSessionState, SessionStateWorkflowEntry entry)
 {
     IAstToWorkflowConverter astToWorkflowConverterAndEnsureWorkflowModuleLoaded = Utils.GetAstToWorkflowConverterAndEnsureWorkflowModuleLoaded(null);
     WorkflowInfo workflowInfo = entry.WorkflowInfo;
     if (workflowInfo == null)
     {
         workflowInfo = astToWorkflowConverterAndEnsureWorkflowModuleLoaded.CompileWorkflow(entry.Name, entry.Definition, initialSessionState);
     }
     WorkflowInfo info2 = new WorkflowInfo(workflowInfo);
     info2 = this.SetWorkflowRaw(info2, CommandOrigin.Internal);
     info2.Visibility = entry.Visibility;
     info2.SetModule(entry.Module);
 }