Table of Contents

Class ContextExtensions

Namespace
NRules.Fluent.Dsl
Assembly
NRules.Fluent.dll
public static class ContextExtensions
Inheritance
ContextExtensions
Inherited Members

Methods

Resolve<TService>(IContext)

Resolves a registered service (normally via an IoC container).

public static TService Resolve<TService>(this IContext context)

Parameters

context IContext

Context instance.

Returns

TService

Service instance.

Type Parameters

TService

Type of service to resolve.

Update<T>(IContext, T, Action<T>)

Updates existing fact in the rules engine's memory. First the update action is applied to the fact, then the fact is updated in the engine's memory.

public static void Update<T>(this IContext context, T fact, Action<T> updateAction)

Parameters

context IContext

Context instance.

fact T

Existing fact to update.

updateAction Action<T>

Action to apply to the fact.

Type Parameters

T