Ejemplo n.º 1
0
        private BehaviorGraph(BehaviorGraph parent) : this()
        {
            _settings = new SettingsCollection(parent._settings);

            // TODO -- use another [IsolatedLevel] attribute on Settings for this
            _settings.Replace(new RouteDefinitionResolver()); // you absolutely have to do this, or you'll get the sources from the parent too.
        }
Ejemplo n.º 2
0
        public BehaviorGraph()
        {
            _settings = new SettingsCollection(null);
            _settings.Replace(SessionStateRequirement.RequiresSessionState);

            RouteIterator = new SortByRouteRankIterator(); // can override in a registry

            TypeResolver = new TypeResolver();
            _services.AddService <ITypeResolver>(TypeResolver);
        }
Ejemplo n.º 3
0
        public BehaviorGraph()
        {
            _log = new ConfigLog(this);

            _settings = new SettingsCollection(null);
            _settings.Replace(SessionStateRequirement.RequiresSessionState);

            RouteIterator = new SortByRouteRankIterator(); // can override in a registry

            TypeResolver = new TypeResolver();
            _services.AddService <ITypeResolver>(TypeResolver);

            Types = new TypePool(null); // need a default for some tests
        }
Ejemplo n.º 4
0
 public void Alter(SettingsCollection settings)
 {
     settings.Replace(_settings);
 }
Ejemplo n.º 5
0
 public SettingsCollection(SettingsCollection parent)
 {
     _settings.OnMissing = buildDefault;
     _parent             = parent;
 }
Ejemplo n.º 6
0
 private BehaviorGraph(BehaviorGraph parent) : this()
 {
     _settings = new SettingsCollection(parent._settings);
 }
Ejemplo n.º 7
0
 public void Alter(SettingsCollection settings)
 {
     settings.Alter(_alteration);
 }
Ejemplo n.º 8
0
 public void Apply(SettingsCollection settings, FubuRegistry registry)
 {
     settings.Get <T>().As <IFeatureSettings>().Apply(registry);
 }
Ejemplo n.º 9
0
 public Task ApplyAll(SettingsCollection settings, FubuRegistry registry)
 {
     return
         (_types.ContinueWith(
              t => { t.Result.Each(type => settings.Get(type).As <IFeatureSettings>().Apply(registry)); }));
 }
Ejemplo n.º 10
0
 public BehaviorGraph(SettingsCollection settings) 
 {
     _settings = settings;
     Routes = new RouteCollection(this);
 }
Ejemplo n.º 11
0
 public BehaviorGraph(SettingsCollection parent) : this()
 {
     _settings = new SettingsCollection(parent);
 }