ClassCatalog Class
Contains all classes in all referenced assemblies. The dictionary key is the full class name and the value is the class type.
Namespace
Statiq.Common
Interfaces
  • IReadOnlyDictionary<string, Type>
  • IReadOnlyCollection<KeyValuePair<string, Type>>
  • IEnumerable<KeyValuePair<string, Type>>
  • IEnumerable
Base Types
  • object
graph BT Type-->Base0["object"] Type-.->Interface0["IReadOnlyDictionary<string, Type>"] Type-.->Interface1["IReadOnlyCollection<KeyValuePair<string, Type>>"] Type-.->Interface2["IEnumerable<KeyValuePair<string, Type>>"] Type-.->Interface3["IEnumerable"] Type["ClassCatalog"] class Type type-node

Syntax

public class ClassCatalog : IReadOnlyDictionary<string, Type>, 
    IReadOnlyCollection<KeyValuePair<string, Type>>, IEnumerable<KeyValuePair<string, Type>>, 
    IEnumerable

Properties

Name Property Type Summary
Count int
Keys IEnumerable<string>
this[string] Type
Values IEnumerable<Type>

Methods

Name Return Value Summary
AddAssemblies(IEnumerable<Assembly>) void
Adds additional assemblies to the catalog.
ContainsKey(string) bool
FindTypes(string, StringComparison) IEnumerable<Type>
Finds types by searching for the provided type name.
FindTypes(string) IEnumerable<Type>
Finds types by searching for the provided type name.
GetAssemblies() IReadOnlyList<Assembly>
Gets all loaded assemblies.
GetEnumerator() IEnumerator<KeyValuePair<string, Type>>
GetInstance(string) object
Gets an instance for a specified full name.
GetInstance(Type, string, bool) object
Gets an instance of a specified assignable type and name.
GetInstance(Type) object
Gets an instance of a specified assignable type and name.
GetInstances(Type) IEnumerable<object>
Gets instances for all classes of a specified assignable type.
GetType(string) Type
Gets a type for the specified full name.
GetTypesAssignableTo(Type, bool) IEnumerable<Type>
Gets all types assignable to a specified type.
GetTypesFromAssembly(Assembly, bool) IEnumerable<Type>
Gets all types from a specified assembly.
LogDebugMessagesTo(ILogger) void
Populate() void
Populates the catalog. Population will only occur once and if the catalog has already been populated this method will immediately return.
TryGetValue(string, Type) bool

Extension Methods

Name Value Summary
Concat<KeyValuePair<string, Type>>(KeyValuePair<string, Type>) IEnumerable<T>
ContainsAnyKeys<string, Type>(IEnumerable<string>) bool
Determines whether the dictionary contains all the specified keys.
ContainsAnyKeys<string, Type>(string[]) bool
Determines whether the dictionary contains all the specified keys.
ContainsKeys<string, Type>(IEnumerable<string>) bool
Determines whether the dictionary contains all the specified keys.
ContainsKeys<string, Type>(string[]) bool
Determines whether the dictionary contains all the specified keys.
GetInstance<T>(string, bool) T
Gets an instance of a specified assignable type and name.
GetInstance<T>() T
Gets an instance of a specified type.
GetInstances<T>() IEnumerable<T>
Gets instances for all classes of a specified assignable type..
GetNext<KeyValuePair<string, Type>>(KeyValuePair<string, Type>, IEqualityComparer<KeyValuePair<string, Type>>) T
GetNext<KeyValuePair<string, Type>>(KeyValuePair<string, Type>) T
GetPrevious<KeyValuePair<string, Type>>(KeyValuePair<string, Type>, IEqualityComparer<KeyValuePair<string, Type>>) T
GetPrevious<KeyValuePair<string, Type>>(KeyValuePair<string, Type>) T
GetTypesAssignableTo<T>(bool) IEnumerable<Type>
Gets all types assignable from a specified type.
GroupByMany<KeyValuePair<string, Type>, TKey, TElement>(Func<KeyValuePair<string, Type>, IEnumerable<TKey>>, Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey, TElement>(Func<KeyValuePair<string, Type>, IEnumerable<TKey>>, Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey>(Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey>(Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey, TElement>(Func<KeyValuePair<string, Type>, IEnumerable<TKey>>, Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey, TElement>(Func<KeyValuePair<string, Type>, IEnumerable<TKey>>, Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>>(Func<KeyValuePair<string, Type>, Task>, CancellationToken) Task
ParallelSelectAsync<KeyValuePair<string, Type>, TResult>(Func<KeyValuePair<string, Type>, Task<TResult>>, CancellationToken) Task<IEnumerable<TResult>>
Invokes an async selector in parallel.
ParallelSelectManyAsync<KeyValuePair<string, Type>, TResult>(Func<KeyValuePair<string, Type>, Task<IEnumerable<TResult>>>, CancellationToken) Task<IEnumerable<TResult>>
Invokes an async selector that returns multiple results in parallel.
ParallelWhereAsync<KeyValuePair<string, Type>>(Func<KeyValuePair<string, Type>, Task<bool>>, CancellationToken) Task<IEnumerable<TSource>>
RequireKeys<string, Type>(IEnumerable<string>) void
Verifies that a dictionary contains all requires keys. An System.ArgumentException will be thrown if the specified keys are not all present in the dictionary.
RequireKeys<string, Type>(string[]) void
Verifies that a dictionary contains all requires keys. An System.ArgumentException will be thrown if the specified keys are not all present in the dictionary.
StartsWith<KeyValuePair<string, Type>>(IEnumerable<KeyValuePair<string, Type>>, IEqualityComparer<KeyValuePair<string, Type>>) bool
Determines whether the items starts with the specified values.
StartsWith<KeyValuePair<string, Type>>(IEnumerable<KeyValuePair<string, Type>>) bool
Determines whether the items starts with the specified values.
ThrowIfNull<ClassCatalog>(string) T
ToDocument<ClassCatalog>(IContentProvider) IDocument
ToDocument<ClassCatalog>(IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocument<ClassCatalog>(NormalizedPath, IContentProvider) IDocument
ToDocument<ClassCatalog>(NormalizedPath, IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocument<ClassCatalog>(NormalizedPath, NormalizedPath, IContentProvider) IDocument
ToDocument<ClassCatalog>(NormalizedPath, NormalizedPath, IEnumerable<KeyValuePair<string, object>>, IContentProvider) IDocument
ToDocuments<KeyValuePair<string, Type>>(Func<KeyValuePair<string, Type>, IContentProvider>) IEnumerable<IDocument>
ToDocuments<KeyValuePair<string, Type>>(Func<KeyValuePair<string, Type>, IEnumerable<KeyValuePair<string, object>>>, Func<KeyValuePair<string, Type>, IContentProvider>) IEnumerable<IDocument>
ToDocuments<KeyValuePair<string, Type>>(Func<KeyValuePair<string, Type>, NormalizedPath>, Func<KeyValuePair<string, Type>, IContentProvider>) IEnumerable<IDocument>
ToDocuments<KeyValuePair<string, Type>>(Func<KeyValuePair<string, Type>, NormalizedPath>, Func<KeyValuePair<string, Type>, IEnumerable<KeyValuePair<string, object>>>, Func<KeyValuePair<string, Type>, IContentProvider>) IEnumerable<IDocument>
ToDocuments<KeyValuePair<string, Type>>(Func<KeyValuePair<string, Type>, NormalizedPath>, Func<KeyValuePair<string, Type>, NormalizedPath>, Func<KeyValuePair<string, Type>, IContentProvider>) IEnumerable<IDocument>
ToDocuments<KeyValuePair<string, Type>>(Func<KeyValuePair<string, Type>, NormalizedPath>, Func<KeyValuePair<string, Type>, NormalizedPath>, Func<KeyValuePair<string, Type>, IEnumerable<KeyValuePair<string, object>>>, Func<KeyValuePair<string, Type>, IContentProvider>) IEnumerable<IDocument>
ToLookupMany<KeyValuePair<string, Type>, TKey, TElement>(Func<KeyValuePair<string, Type>, IEnumerable<TKey>>, Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey, TElement>(Func<KeyValuePair<string, Type>, IEnumerable<TKey>>, Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey>(Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey>(Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey, TElement>(Func<KeyValuePair<string, Type>, IEnumerable<TKey>>, Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>, TKey, TElement>(Func<KeyValuePair<string, Type>, IEnumerable<TKey>>, Func<KeyValuePair<string, Type>, 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<KeyValuePair<string, Type>>(string[], Func<KeyValuePair<string, Type>, object>[]) string