コード例 #1
0
        private IDictionary <int, ActEntryTemplate> buildResultsFor(WorkflowObject workflowObject)
        {
            var results = new Dictionary <int, ActEntryTemplate>();

            DefaultPolicy.RenderTemplate(workflowObject, results);

            Policies.Each(p => p.RenderTemplate(workflowObject, results));

            return(results);
        }
        private IDictionary <int, ActEntryTemplate> buildTemplatesFor(WorkflowObject workflowObject)
        {
            var results = new Dictionary <int, ActEntryTemplate>();

            //Setup default template to be used when act_entries with no template are found in the results
            //TODO allow better customization of how the default template is defined
            var defaultTemplate = _container.GetInstance <ActEntryTemplate>();

            defaultTemplate.Code = DefaultActEntryTemplateMagicCode;
            results.Add(DefaultActEntryTemplateMagicCode, defaultTemplate);

            DefaultPolicy.RenderTemplate(workflowObject, results);

            Policies.Each(p => p.RenderTemplate(workflowObject, results));

            return(results);
        }