Ejemplo n.º 1
0
        public ConfigGraph(Assembly applicationAssembly)
        {
            _applicationAssembly = applicationAssembly;
            _actionSourceAggregator = new ActionSourceAggregator(_applicationAssembly);

            _sources.Add(_actionSourceAggregator);
        }
Ejemplo n.º 2
0
        public ConfigGraph(Assembly applicationAssembly)
        {
            _applicationAssembly    = applicationAssembly;
            _actionSourceAggregator = new ActionSourceAggregator(_applicationAssembly);

            _sources.Add(_actionSourceAggregator);
            _sources.Add(_handlers);
        }
Ejemplo n.º 3
0
        public ConfigGraph(Assembly applicationAssembly)
        {
            _applicationAssembly = applicationAssembly;
            _actionSourceAggregator = new ActionSourceAggregator(_applicationAssembly);

            _sources.Add(_actionSourceAggregator);
            _sources.Add(_handlers);
            _sources.Add(new ActionlessViewChainSource());
        }
Ejemplo n.º 4
0
        private static void discoverChains(ConfigGraph config, BehaviorGraph graph)
        {
            var chainSources = config.Sources.Union(config.UniqueImports()).ToList();
            if (FubuMode.InDevelopment())
            {
                var aggregator = new ActionSourceAggregator(null);
                aggregator.Add(new RegisterAbout());

                chainSources.Add(aggregator);
            }

            var tasks =
                chainSources.Select(
                    x => {
                        return
                            Task.Factory.StartNew(() => { x.BuildChains(graph.Settings).Each(chain => graph.AddChain(chain)); });
                    }).ToArray();

            Task.WaitAll(tasks);
        }