本文整理匯總了C#中BehaviorGraph類的典型用法代碼示例。如果您正苦於以下問題:C# BehaviorGraph類的具體用法?C# BehaviorGraph怎麽用?C# BehaviorGraph使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
BehaviorGraph類屬於命名空間,在下文中一共展示了BehaviorGraph類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: BehaviorGraphWriter
public BehaviorGraphWriter(BehaviorGraph graph, IUrlRegistry urls, IServiceLocator services)
{
_graph = graph;
_urls = urls;
_services = services;
_diagnosticsNamespace = GetType().Namespace;
}
示例2: SetUp
public void SetUp()
{
var registry = new FubuRegistry();
registry.Import<ApplyWindowsAuthentication>();
theGraph = BehaviorGraph.BuildFrom(registry);
}
示例3: Configure
public void Configure(BehaviorGraph graph)
{
graph.Behaviors
.Where(x => !x.IsPartialOnly)
.Where(x => x.ResourceType().CanBeCastTo<JsonMessage>() || x.InputType().CanBeCastTo<JsonMessage>())
.Each(x => x.MakeAsymmetricJson());
}
示例4: SetUp
public void SetUp()
{
var registry = new FubuRegistry();
registry.Import<ServerSentEventsExtension>();
theGraph = BehaviorGraph.BuildFrom(registry);
}
開發者ID:DarthFubuMVC,項目名稱:FubuMVC.ServerSentEvents,代碼行數:7,代碼來源:ServerSentEventExtensionIntegratedTester.cs
示例5: PartialFactory
public PartialFactory(BehaviorGraph graph, IBehaviorFactory factory, ServiceArguments arguments, ICurrentChain currentChain)
{
_graph = graph;
_factory = factory;
_arguments = arguments;
_currentChain = currentChain;
}
示例6: SetUp
public void SetUp()
{
theGraph = BehaviorGraph.BuildFrom(x =>
{
x.Actions.IncludeClassesSuffixedWithController();
});
}
示例7: SetUp
public void SetUp()
{
var registry = new FubuRegistry();
registry.Actions.IncludeType<RouteAliasController>();
theGraph = BehaviorGraph.BuildFrom(registry);
}
示例8: Configure
public void Configure(BehaviorGraph graph)
{
graph.Behaviors
.Where(x => !x.IsPartialOnly)
.Where(x => x.HasResourceType() && !x.HasOutput())
.Each(x => x.ApplyConneg());
}
示例9: beforeAll
public void beforeAll()
{
var registry = new FubuRegistry();
registry.Actions.IncludeType<Controller1>();
_graph = BehaviorGraph.BuildFrom(registry);
}
示例10: SetUp
public void SetUp()
{
graph = new BehaviorGraph(null);
matcher = new ActionSourceMatcher();
pool = new TypePool();
}
示例11: Configure
public void Configure(BehaviorGraph graph)
{
graph.Behaviors
.Where(x => x.ResourceType().CanBeCastTo<AjaxContinuation>())
.ToList()
.Each(Modify);
}
示例12: Configure
public void Configure(BehaviorGraph graph)
{
graph
.Actions()
.Where(c => !c.HandlerType.Namespace.Contains("Login") && !c.HandlerType.Namespace.Contains("Home"))
.Each(c => c.WrapWith<AuthenticationRequiredBehavior>());
}
示例13: Configure
public void Configure(BehaviorGraph graph)
{
graph
.Actions()
.Where(c => c.HasAttribute<SecureAttribute>())
.Each(c => c.WrapWith<AuthenticationRequiredBehaviour>());
}
示例14: Configure
public void Configure(BehaviorGraph graph)
{
var jobs = graph.Settings.Get<PollingJobSettings>().Jobs;
jobs.Select(x => x.ToObjectDef())
.Each(x => graph.Services.AddService(typeof(IPollingJob), x));
}
示例15:
void IConfigurationAction.Configure(BehaviorGraph graph)
{
var chain = graph.BehaviorFor(_route);
_nodes.Each(chain.AddToEnd);
//graph.Observer.RecordStatus("Adding explicit route {0}".ToFormat(_route));
}