Table of Contents

Class Notifiable

Namespace
NMF.Expressions
Assembly
NMF.Expressions.dll

Represents a node in a graph which can notify its successors and gets notified by its dependencies.

public abstract class Notifiable : INotifiable, IDisposable, ISuccessorList
Inheritance
Notifiable
Implements
Inherited Members
Extension Methods

Properties

AllSuccessors

public IEnumerable<INotifiable> AllSuccessors { get; }

Property Value

IEnumerable<INotifiable>

Count

The number of elements

public int Count { get; }

Property Value

int

Dependencies

Nodes that notify this node.

public abstract IEnumerable<INotifiable> Dependencies { get; }

Property Value

IEnumerable<INotifiable>

ExecutionMetaData

Used by the execution engine during incremental execution.

public ExecutionMetaData ExecutionMetaData { get; }

Property Value

ExecutionMetaData

HasSuccessors

True, if there is any successor, otherwise False

public bool HasSuccessors { get; }

Property Value

bool

IsAttached

True, if successors are attached, otherwise False

public bool IsAttached { get; }

Property Value

bool

this[int]

public INotifiable this[int index] { get; }

Parameters

index int

Property Value

INotifiable

Successors

The nodes that will get notified by this node.

public ISuccessorList Successors { get; }

Property Value

ISuccessorList

Methods

Attach()

Gets called when there is a client

protected virtual void Attach()

Detach()

Gets called when there is no client any more

protected virtual void Detach()

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose()

GetEnumerator()

public IEnumerator<INotifiable> GetEnumerator()

Returns

IEnumerator<INotifiable>

GetSuccessor(int)

Gets the successor with the given index

public INotifiable GetSuccessor(int index)

Parameters

index int

the index

Returns

INotifiable

the succesor DDG node with the given index

Notify(IList<INotificationResult>)

Gets called when one of the dependencies signals a notification.

public abstract INotificationResult Notify(IList<INotificationResult> sources)

Parameters

sources IList<INotificationResult>

Contains information about what triggered this notification.

Returns

INotificationResult

An object describing the changes that happened in this notification.

Set(INotifiable)

Add the given DDG node to the list

public void Set(INotifiable node)

Parameters

node INotifiable

The DDG node to add

SetDummy()

Sets a dummy

public void SetDummy()

Unset(INotifiable, bool)

Unset the given DDG node as successor

public void Unset(INotifiable node, bool leaveDummy = false)

Parameters

node INotifiable

the DDG node

leaveDummy bool

True, to leave the dummy in operation, otherwise False

UnsetAll()

Clear the list

public void UnsetAll()

Events

Attached

public event EventHandler Attached

Event Type

EventHandler

Detached

public event EventHandler Detached

Event Type

EventHandler