ModuleList Class
A collection of modules.
Namespace
Statiq.Common
Interfaces
Base Types
  • object
Derived Types
graph BT Type-->Base0["object"] Type-.->Interface0["IList<IModule>"] Type-.->Interface1["ICollection<IModule>"] Type-.->Interface2["IEnumerable<IModule>"] Type-.->Interface3["IEnumerable"] Type["ModuleList"] class Type type-node Derived0["IfCondition"]-->Type click Derived0 "/api/Statiq.Core/IfCondition"

Syntax

public class ModuleList : IList<IModule>, ICollection<IModule>, IEnumerable<IModule>, IEnumerable

Constructors

Name Summary
ModuleList() Creates a new empty module list.
ModuleList(IEnumerable<IModule>) Creates a new module list with an initial set of modules. Any null items in the sequence of modules will be discarded.
ModuleList(IModule[]) Creates a new module list with an initial set of modules. Any null items in the sequence of modules will be discarded.

Properties

Name Property Type Summary
Count int
IsReadOnly bool
this[int] IModule

Methods

Name Return Value Summary
Add(IModule[]) void
Adds modules to the list. Any null items in the sequence of modules will be discarded.
AddRange(IEnumerable<IModule>) void
Adds modules to the list. Any null items in the sequence of modules will be discarded.
Append(IModule[]) ModuleList
Appends modules.
Clear() void
Contains(IModule) bool
CopyTo(IModule[], int) void
GetEnumerator() IEnumerator<IModule>
GetFirst<TModule>() TModule
Gets the first module of the specified type.
GetFirst<TModule>(Predicate<TModule>) TModule
Gets the first module of the specified type.
GetLast<TModule>() TModule
Gets the last module of the specified type.
GetLast<TModule>(Predicate<TModule>) TModule
Gets the last module of the specified type.
IndexOf(IModule) int
IndexOfFirst<TModule>() int
Gets the index of the first module of the specified type.
IndexOfFirst<TModule>(Predicate<TModule>) int
Gets the index of the first module of the specified type.
IndexOfLast<TModule>() int
Gets the index of the last module of the specified type.
IndexOfLast<TModule>(Predicate<TModule>) int
Gets the index of the last module of the specified type.
Insert(int, IModule) void
Insert(int, IModule[]) void
Inserts modules into the list. Any null items in the sequence of modules will be discarded.
InsertAfterFirst<TModule>(IModule[]) ModuleList
Inserts modules after the first module in the list of the specified type.
InsertAfterFirst<TModule>(Predicate<TModule>, IModule[]) ModuleList
Inserts modules after the first module in the list of the specified type that satisfies a predicate.
InsertAfterLast<TModule>(IModule[]) ModuleList
Inserts modules after the last module in the list of the specified type.
InsertAfterLast<TModule>(Predicate<TModule>, IModule[]) ModuleList
Inserts modules after the last module in the list of the specified type that satisfies a predicate.
InsertBeforeFirst<TModule>(IModule[]) ModuleList
Inserts modules before the first module in the list of the specified type.
InsertBeforeFirst<TModule>(Predicate<TModule>, IModule[]) ModuleList
Inserts modules before the first module in the list of the specified type that satisfies a predicate.
InsertBeforeLast<TModule>(IModule[]) ModuleList
Inserts modules before the last module in the list of the specified type.
InsertBeforeLast<TModule>(Predicate<TModule>, IModule[]) ModuleList
Inserts modules before the last module in the list of the specified type that satisfies a predicate.
InsertRange(int, IEnumerable<IModule>) void
Inserts modules into the list. Any null items in the sequence of modules will be discarded.
Modify(int, Action<IModule>) ModuleList
Modifies an inner module list with the specified index.
Prepend(IModule[]) ModuleList
Prepends modules.
Remove(IModule) bool
RemoveAt(int) void
Replace(int, IModule) ModuleList
Replaces a module at the specified index.
ReplaceFirst<TModule>(IModule) ModuleList
Replaces the first module in the list of the specified type.
ReplaceFirst<TModule>(Predicate<TModule>, IModule) ModuleList
Replaces the first module in the list of the specified type that satisfies a predicate.
ReplaceLast<TModule>(IModule) ModuleList
Replaces the last module in the list of the specified type.
ReplaceLast<TModule>(Predicate<TModule>, IModule) ModuleList
Replaces the last module in the list of the specified type that satisfies a predicate.

Operators

Name Value Summary
implicit operator ModuleList(IModule[]) ModuleList

Extension Methods

Name Value Summary
AddRange<IModule>(IEnumerable<IModule>) void
Adds a range of values to a collection.
AddRange<IModule>(IModule[]) void
Adds a range of values to a collection.
Concat<IModule>(IModule) IEnumerable<T>
GetNext<IModule>(IModule, IEqualityComparer<IModule>) T
GetNext<IModule>(IModule) T
GetPrevious<IModule>(IModule, IEqualityComparer<IModule>) T
GetPrevious<IModule>(IModule) T
GroupByMany<IModule, TKey, TElement>(Func<IModule, IEnumerable<TKey>>, Func<IModule, TElement>, IEqualityComparer<TKey>) IEnumerable<IGrouping<TKey, TElement>>
Groups the elements of a sequence according to a specified key selector function that returns a sequence of keys. The keys are compared by using a comparer and each group's elements are projected by using a specified function.
GroupByMany<IModule, TKey, TElement>(Func<IModule, IEnumerable<TKey>>, Func<IModule, TElement>) IEnumerable<IGrouping<TKey, TElement>>
Groups the elements of a sequence according to a specified key selector function that returns a sequence of keys and projects the elements for each group by using a specified function.
GroupByMany<IModule, TKey>(Func<IModule, IEnumerable<TKey>>, IEqualityComparer<TKey>) IEnumerable<IGrouping<TKey, TSource>>
Groups the elements of a sequence according to a specified key selector function that returns a sequence of keys and compares the keys by using a specified comparer.
GroupByMany<IModule, TKey>(Func<IModule, IEnumerable<TKey>>) IEnumerable<IGrouping<TKey, TSource>>
Groups the elements of a sequence according to a specified key selector function that returns a sequence of keys.
GroupByManyToMany<IModule, TKey, TElement>(Func<IModule, IEnumerable<TKey>>, Func<IModule, IEnumerable<TElement>>, IEqualityComparer<TKey>) IEnumerable<IGrouping<TKey, TElement>>
Groups the elements of a sequence according to a specified key selector function that returns a sequence of keys. The keys are compared by using a comparer and each group's elements are projected by using a specified function that returns a sequence of elements.
GroupByManyToMany<IModule, TKey, TElement>(Func<IModule, IEnumerable<TKey>>, Func<IModule, IEnumerable<TElement>>) IEnumerable<IGrouping<TKey, TElement>>
Groups the elements of a sequence according to a specified key selector function that returns a sequence of keys and projects the elements for each group by using a specified function that returns a sequence of elements.
ParallelForEachAsync<IModule>(Func<IModule, Task>, CancellationToken) Task
ParallelSelectAsync<IModule, TResult>(Func<IModule, Task<TResult>>, CancellationToken) Task<IEnumerable<TResult>>
Invokes an async selector in parallel.
ParallelSelectManyAsync<IModule, TResult>(Func<IModule, Task<IEnumerable<TResult>>>, CancellationToken) Task<IEnumerable<TResult>>
Invokes an async selector that returns multiple results in parallel.
ParallelWhereAsync<IModule>(Func<IModule, Task<bool>>, CancellationToken) Task<IEnumerable<TSource>>
RemoveAll<IModule>(Func<IModule, bool>) int
Removes all items that match a predicate from a collection.
StartsWith<IModule>(IEnumerable<IModule>, IEqualityComparer<IModule>) bool
Determines whether the items starts with the specified values.
StartsWith<IModule>(IEnumerable<IModule>) bool
Determines whether the items starts with the specified values.
ThrowIfNull<ModuleList>(string) T
ToDocument<ModuleList>(IContentProvider) IDocument
ToDocument<ModuleList>(IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocument<ModuleList>(NormalizedPath, IContentProvider) IDocument
ToDocument<ModuleList>(NormalizedPath, IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocument<ModuleList>(NormalizedPath, NormalizedPath, IContentProvider) IDocument
ToDocument<ModuleList>(NormalizedPath, NormalizedPath, IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocuments<IModule>(Func<IModule, IContentProvider>) IEnumerable<IDocument>
ToDocuments<IModule>(Func<IModule, IEnumerable<KeyValuePair<string, object>>>, Func<IModule, IContentProvider>) IEnumerable<IDocument>
ToDocuments<IModule>(Func<IModule, NormalizedPath>, Func<IModule, IContentProvider>) IEnumerable<IDocument>
ToDocuments<IModule>(Func<IModule, NormalizedPath>, Func<IModule, IEnumerable<KeyValuePair<string, object>>>, Func<IModule, IContentProvider>) IEnumerable<IDocument>
ToDocuments<IModule>(Func<IModule, NormalizedPath>, Func<IModule, NormalizedPath>, Func<IModule, IContentProvider>) IEnumerable<IDocument>
ToDocuments<IModule>(Func<IModule, NormalizedPath>, Func<IModule, NormalizedPath>, Func<IModule, IEnumerable<KeyValuePair<string, object>>>, Func<IModule, IContentProvider>) IEnumerable<IDocument>
ToLookupMany<IModule, TKey, TElement>(Func<IModule, IEnumerable<TKey>>, Func<IModule, TElement>, IEqualityComparer<TKey>) ILookup<TKey, TElement>
Creates a lookup from a sequence according to a specified key selector function that returns a sequence of keys. The keys are compared by using a comparer and each group's elements are projected by using a specified function.
ToLookupMany<IModule, TKey, TElement>(Func<IModule, IEnumerable<TKey>>, Func<IModule, TElement>) ILookup<TKey, TElement>
Creates a lookup from a sequence according to a specified key selector function that returns a sequence of keys and projects the elements for each group by using a specified function.
ToLookupMany<IModule, TKey>(Func<IModule, IEnumerable<TKey>>, IEqualityComparer<TKey>) ILookup<TKey, TSource>
Creates a lookup from a sequence according to a specified key selector function that returns a sequence of keys and compares the keys by using a specified comparer.
ToLookupMany<IModule, TKey>(Func<IModule, IEnumerable<TKey>>) ILookup<TKey, TSource>
Creates a lookup from a sequence according to a specified key selector function that returns a sequence of keys.
ToLookupManyToMany<IModule, TKey, TElement>(Func<IModule, IEnumerable<TKey>>, Func<IModule, IEnumerable<TElement>>, IEqualityComparer<TKey>) ILookup<TKey, TElement>
Creates a lookup from a sequence according to a specified key selector function that returns a sequence of keys. The keys are compared by using a comparer and each group's elements are projected by using a specified function that returns a sequence of elements.
ToLookupManyToMany<IModule, TKey, TElement>(Func<IModule, IEnumerable<TKey>>, Func<IModule, IEnumerable<TElement>>) ILookup<TKey, TElement>
Creates a lookup from a sequence according to a specified key selector function that returns a sequence of keys and projects the elements for each group by using a specified function that returns a sequence of elements.
ToStringTable<IModule>(string[], Func<IModule, object>[]) string