Class NotifyCollection<T>
- Namespace
- NMF.Expressions
- Assembly
- NMF.Expressions.Linq.dll
Denotes a collection that listens for updates
public class NotifyCollection<T> : ObservableCollection<T>, IList<T>, IReadOnlyList<T>, IReadOnlyCollection<T>, IList, ICollection, INotifyPropertyChanged, INotifyCollection<T>, INotifyEnumerable<T>, INotifyEnumerable, INotifyCollectionChanged, INotifiable, IDisposable, ICollectionExpression<T>, IEnumerableExpression<T>, IEnumerableExpression, ICollection<T>, IEnumerable<T>, IEnumerable, ISuccessorList
Type Parameters
TThe type of elements
- Inheritance
-
Collection<T>NotifyCollection<T>
- Implements
-
IList<T>ICollection<T>IEnumerable<T>
- Inherited Members
- Extension Methods
-
ExpressionExtensions.Count<TSource>(IEnumerableExpression<TSource>, Expression<Func<TSource, bool>>)ExpressionExtensions.IsSupersetOf<T>(IEnumerableExpression<T>, IEnumerable<T>, IEqualityComparer<T>)ExpressionExtensions.Sum<TSource>(IEnumerableExpression<TSource>, Expression<Func<TSource, double>>)ExpressionExtensions.Sum<TSource>(IEnumerableExpression<TSource>, Expression<Func<TSource, float?>>)ObservableExtensions.Average<TSource>(INotifyEnumerable<TSource>, Expression<Func<TSource, double>>)ObservableExtensions.Average<TSource>(INotifyEnumerable<TSource>, Expression<Func<TSource, float?>>)ObservableExtensions.IsProperSubsetOf<T>(INotifyEnumerable<T>, IEnumerable<T>, IEqualityComparer<T>)ObservableExtensions.TopX<TItem, TKey>(INotifyEnumerable<TItem>, int, Expression<Func<TItem, TKey>>)
Constructors
NotifyCollection()
Creates a new instance
public NotifyCollection()
Properties
AllSuccessors
public IEnumerable<INotifiable> AllSuccessors { get; }
Property Value
Dependencies
Nodes that notify this node.
public virtual IEnumerable<INotifiable> Dependencies { get; }
Property Value
ExecutionMetaData
Used by the execution engine during incremental execution.
public ExecutionMetaData ExecutionMetaData { get; }
Property Value
HasSuccessors
True, if there is any successor, otherwise False
public bool HasSuccessors { get; }
Property Value
IsAttached
True, if successors are attached, otherwise False
public bool IsAttached { get; }
Property Value
Successors
The nodes that will get notified by this node.
public ISuccessorList Successors { get; }
Property Value
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public void Dispose()
GetSuccessor(int)
Gets the successor at the given index
public INotifiable GetSuccessor(int index)
Parameters
indexintThe index
Returns
- INotifiable
The DDG node with the given index
Notify(IList<INotificationResult>)
Gets called when one of the dependencies signals a notification.
public virtual INotificationResult Notify(IList<INotificationResult> sources)
Parameters
sourcesIList<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
nodeINotifiableThe DDG node to add
SetDummy()
Sets a dummy
public void SetDummy()
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.
Unset(INotifiable, bool)
Unset the given DDG node as successor
public void Unset(INotifiable node, bool leaveDummy = false)
Parameters
nodeINotifiablethe DDG node
leaveDummyboolTrue, to leave the dummy in operation, otherwise False
UnsetAll()
Clear the list
public void UnsetAll()