public WfDocGenerator(List<ActivityChainModel> activities, RulesExtractor rulesExtractor, Settings Settings)
            : base(activities, rulesExtractor, Settings)
        {
            if (Settings.GetLanguage() < OutputFormat.Docx)
                throw new NotSupportedException("Output Language not supported:" + Settings.GetLanguage());

            Name = "Workflow to Code Generator";
        }
        public RulesConverter(RulesExtractor ruleExtractor, bool runAsync)
        {
            if (ruleExtractor == null)
            {
                throw new ArgumentNullException("ruleExtractor");
            }

            if (ruleExtractor.RuleDefinitions == null)
            {
                SendMessage("Rule definitions have not been extracted", EventType.Output);
                ruleExtractor.GetRuleDefinitions();
            }

            _ruleDefinitions = ruleExtractor.RuleDefinitions;
            _runAsync        = runAsync;
        }
        protected WorkflowOutputGenerator(List<ActivityChainModel> activities, 
            RulesExtractor rulesExtractor,
            Settings Settings)
        {
            if (activities == null)
                throw new ArgumentNullException("activities");

            if (rulesExtractor == null)
                throw new ArgumentNullException("rulesExtractor");

            if (Settings == null)
                throw new ArgumentNullException("Settings");

            _activities = activities;
            _settings = Settings;
            _rulesExtractor = rulesExtractor;
        }
        internal WorkflowConverter(WorkflowExtractor extractor, RulesExtractor rulesExtractor)
        {
            if (extractor == null)
            {
                throw new ArgumentNullException("extractor");
            }

            if (rulesExtractor == null)
            {
                throw new ArgumentNullException("rulesExtractor");
            }

            _generatorsTypes = new List <GeneratorTypes>();

            if (extractor.Activities == null)
            {
                extractor.GetActivityTree();
            }

            _extractor      = extractor;
            _rulesExtractor = rulesExtractor;
        }