Class LazyCollectionBuilderBase<TBuilder, TCollection, TItem>
Implements a lazy collection builder.
Namespace: Umbraco.Cms.Core.Composing
Assembly: Umbraco.Core.dll
Syntax
public abstract class LazyCollectionBuilderBase<TBuilder, TCollection, TItem> : CollectionBuilderBase<TBuilder, TCollection, TItem>, ICollectionBuilder<TCollection, TItem>, ICollectionBuilder where TBuilder : LazyCollectionBuilderBase<TBuilder, TCollection, TItem> where TCollection : class, IBuilderCollection<TItem>
Type Parameters
Name | Description |
---|---|
TBuilder | The type of the builder. |
TCollection | The type of the collection. |
TItem | The type of the items. |
Remarks
This type of collection builder is typically used when type scanning is required (i.e. plugins).
Properties
View SourceThis
Declaration
protected abstract TBuilder This { get; }
Property Value
Type | Description |
---|---|
TBuilder |
Methods
View SourceAdd(Func<IEnumerable<Type>>)
Adds a types producer to the collection.
Declaration
public TBuilder Add(Func<IEnumerable<Type>> producer)
Parameters
Type | Name | Description |
---|---|---|
Func<IEnumerable<Type>> | producer | The types producer. |
Returns
Type | Description |
---|---|
TBuilder | The builder. |
Add(Type)
Adds a type to the collection.
Declaration
public TBuilder Add(Type type)
Parameters
Type | Name | Description |
---|---|---|
Type | type | The type to add. |
Returns
Type | Description |
---|---|
TBuilder | The builder. |
Add<T>()
Adds a type to the collection.
Declaration
public TBuilder Add<T>()
where T : TItem
Returns
Type | Description |
---|---|
TBuilder | The builder. |
Type Parameters
Name | Description |
---|---|
T | The type to add. |
Clear()
Clears all types in the collection.
Declaration
public TBuilder Clear()
Returns
Type | Description |
---|---|
TBuilder | The builder. |
Exclude(Type)
Excludes a type from the collection.
Declaration
public TBuilder Exclude(Type type)
Parameters
Type | Name | Description |
---|---|---|
Type | type | The type to exclude. |
Returns
Type | Description |
---|---|
TBuilder | The builder. |
Exclude<T>()
Excludes a type from the collection.
Declaration
public TBuilder Exclude<T>()
where T : TItem
Returns
Type | Description |
---|---|
TBuilder | The builder. |
Type Parameters
Name | Description |
---|---|
T | The type to exclude. |
GetRegisteringTypes(IEnumerable<Type>)
Declaration
protected override IEnumerable<Type> GetRegisteringTypes(IEnumerable<Type> types)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<Type> | types |
Returns
Type | Description |
---|---|
IEnumerable<Type> |