PathCollection Class
An ordered collection of unique NormalizedPath.
Namespace
Statiq.Common
Interfaces
Base Types
  • object
graph BT Type-->Base0["object"] Type-.->Interface0["IReadOnlyList<NormalizedPath>"] Type-.->Interface1["IReadOnlyCollection<NormalizedPath>"] Type-.->Interface2["IEnumerable<NormalizedPath>"] Type-.->Interface3["IEnumerable"] Type["PathCollection"] class Type type-node

Syntax

public class PathCollection : IReadOnlyList<NormalizedPath>, IReadOnlyCollection<NormalizedPath>, 
    IEnumerable<NormalizedPath>, IEnumerable

Constructors

Name Summary
PathCollection() Initializes a new path collection.
PathCollection(IEnumerable<NormalizedPath>) Initializes a new path collection.
PathCollection(NormalizedPath[]) Initializes a new path collection.

Properties

Name Property Type Summary
Count int
Gets the number of directories in the collection.
this[int] NormalizedPath
Gets or sets the NormalizedPath at the specified index.

Methods

Name Return Value Summary
Add(NormalizedPath, bool) bool
Adds the specified path to the collection.
Add(NormalizedPath) bool
Adds the specified path to the collection.
AddRange(IEnumerable<NormalizedPath>, bool) void
Adds the specified paths to the collection.
AddRange(IEnumerable<NormalizedPath>) void
Adds the specified paths to the collection.
Clear() void
Clears all removable paths from the collection.
Contains(NormalizedPath) bool
Determines whether the collection contains the specified path.
GetEnumerator() IEnumerator<NormalizedPath>
Returns an enumerator that iterates through the collection.
IndexOf(NormalizedPath) int
Returns the index of the specified path.
Insert(int, NormalizedPath, bool) bool
Inserts the path at the specified index.
Insert(int, NormalizedPath) bool
Inserts the path at the specified index.
Remove(NormalizedPath) bool
Removes the specified path.
RemoveAt(int) void
Removes the path at the specified index if it's removable.
RemoveRange(IEnumerable<NormalizedPath>) void
Removes the specified paths from the collection if they're removable.

Extension Methods

Name Value Summary
Concat<NormalizedPath>(NormalizedPath) IEnumerable<T>
Contains<NormalizedPath>(IReadOnlyList<NormalizedPath>, EqualityComparer<NormalizedPath>) bool
Contains<NormalizedPath>(IReadOnlyList<NormalizedPath>, int, EqualityComparer<NormalizedPath>) bool
Contains<NormalizedPath>(IReadOnlyList<NormalizedPath>, int) bool
Contains<NormalizedPath>(IReadOnlyList<NormalizedPath>) bool
GetNext<NormalizedPath>(NormalizedPath, IEqualityComparer<NormalizedPath>) T
GetNext<NormalizedPath>(NormalizedPath) T
GetPrevious<NormalizedPath>(NormalizedPath, IEqualityComparer<NormalizedPath>) T
GetPrevious<NormalizedPath>(NormalizedPath) T
GroupByMany<NormalizedPath, TKey, TElement>(Func<NormalizedPath, IEnumerable<TKey>>, Func<NormalizedPath, 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<NormalizedPath, TKey, TElement>(Func<NormalizedPath, IEnumerable<TKey>>, Func<NormalizedPath, 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<NormalizedPath, TKey>(Func<NormalizedPath, 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<NormalizedPath, TKey>(Func<NormalizedPath, 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<NormalizedPath, TKey, TElement>(Func<NormalizedPath, IEnumerable<TKey>>, Func<NormalizedPath, 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<NormalizedPath, TKey, TElement>(Func<NormalizedPath, IEnumerable<TKey>>, Func<NormalizedPath, 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.
IndexOf<NormalizedPath>(IReadOnlyList<NormalizedPath>, EqualityComparer<NormalizedPath>) int
IndexOf<NormalizedPath>(IReadOnlyList<NormalizedPath>) int
ParallelForEachAsync<NormalizedPath>(Func<NormalizedPath, Task>, CancellationToken) Task
ParallelSelectAsync<NormalizedPath, TResult>(Func<NormalizedPath, Task<TResult>>, CancellationToken) Task<IEnumerable<TResult>>
Invokes an async selector in parallel.
ParallelSelectManyAsync<NormalizedPath, TResult>(Func<NormalizedPath, Task<IEnumerable<TResult>>>, CancellationToken) Task<IEnumerable<TResult>>
Invokes an async selector that returns multiple results in parallel.
ParallelWhereAsync<NormalizedPath>(Func<NormalizedPath, Task<bool>>, CancellationToken) Task<IEnumerable<TSource>>
StartsWith<NormalizedPath>(IEnumerable<NormalizedPath>, IEqualityComparer<NormalizedPath>) bool
Determines whether the items starts with the specified values.
StartsWith<NormalizedPath>(IEnumerable<NormalizedPath>) bool
Determines whether the items starts with the specified values.
ThrowIfNull<PathCollection>(string) T
ToDocument<PathCollection>(IContentProvider) IDocument
ToDocument<PathCollection>(IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocument<PathCollection>(NormalizedPath, IContentProvider) IDocument
ToDocument<PathCollection>(NormalizedPath, IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocument<PathCollection>(NormalizedPath, NormalizedPath, IContentProvider) IDocument
ToDocument<PathCollection>(NormalizedPath, NormalizedPath, IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocuments<NormalizedPath>(Func<NormalizedPath, IContentProvider>) IEnumerable<IDocument>
ToDocuments<NormalizedPath>(Func<NormalizedPath, IEnumerable<KeyValuePair<string, object>>>, Func<NormalizedPath, IContentProvider>) IEnumerable<IDocument>
ToDocuments<NormalizedPath>(Func<NormalizedPath, NormalizedPath>, Func<NormalizedPath, IContentProvider>) IEnumerable<IDocument>
ToDocuments<NormalizedPath>(Func<NormalizedPath, NormalizedPath>, Func<NormalizedPath, IEnumerable<KeyValuePair<string, object>>>, Func<NormalizedPath, IContentProvider>) IEnumerable<IDocument>
ToDocuments<NormalizedPath>(Func<NormalizedPath, NormalizedPath>, Func<NormalizedPath, NormalizedPath>, Func<NormalizedPath, IContentProvider>) IEnumerable<IDocument>
ToDocuments<NormalizedPath>(Func<NormalizedPath, NormalizedPath>, Func<NormalizedPath, NormalizedPath>, Func<NormalizedPath, IEnumerable<KeyValuePair<string, object>>>, Func<NormalizedPath, IContentProvider>) IEnumerable<IDocument>
ToLookupMany<NormalizedPath, TKey, TElement>(Func<NormalizedPath, IEnumerable<TKey>>, Func<NormalizedPath, 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<NormalizedPath, TKey, TElement>(Func<NormalizedPath, IEnumerable<TKey>>, Func<NormalizedPath, 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<NormalizedPath, TKey>(Func<NormalizedPath, 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<NormalizedPath, TKey>(Func<NormalizedPath, 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<NormalizedPath, TKey, TElement>(Func<NormalizedPath, IEnumerable<TKey>>, Func<NormalizedPath, 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<NormalizedPath, TKey, TElement>(Func<NormalizedPath, IEnumerable<TKey>>, Func<NormalizedPath, 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<NormalizedPath>(string[], Func<NormalizedPath, object>[]) string