Table of Contents

Interface IAgenda

Namespace
NRules
Assembly
NRules.dll

Agenda stores matches between rules and facts. These matches are called activations. Multiple activations are ordered according to the conflict resolution strategy.

public interface IAgenda

Properties

IsEmpty

Indicates whether there are any activations in the agenda.

bool IsEmpty { get; }

Property Value

bool

If agenda is empty then true otherwise false.

Methods

AddFilter(IAgendaFilter)

Adds a global filter to the agenda.

void AddFilter(IAgendaFilter filter)

Parameters

filter IAgendaFilter

Filter to be applied to all activations before they are placed on the agenda.

AddFilter(IRuleDefinition, IAgendaFilter)

Adds a rule-level filter to the agenda.

void AddFilter(IRuleDefinition rule, IAgendaFilter filter)

Parameters

rule IRuleDefinition

Rule, whose activations are to be filtered before placing them on the agenda.

filter IAgendaFilter

Filter to be applied to all activations for a given rule before they are placed on the agenda.

Clear()

Removes all matches from agenda.

void Clear()

Peek()

Retrieves the next match, without removing it from agenda.

IMatch Peek()

Returns

IMatch

Next match.

Remarks

Throws InvalidOperationException if agenda is empty.

See Also