Class OptionsBase<TFluentType, TOptionType>
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Base class for options supporting fluent operations based on a specifiec option type
Inheritance
Implements
Inherited Members
Namespace: EPiServer.Core.Internal
Assembly: EPiServer.dll
Version: 10.10.4Syntax
public abstract class OptionsBase<TFluentType, TOptionType> : IEnumerable<TOptionType>, IEnumerable where TFluentType : classType Parameters
| Name | Description | 
|---|---|
| TFluentType | |
| TOptionType | 
Constructors
OptionsBase()
Declaration
protected OptionsBase()Methods
Add<T>(T)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Adds a new option
Declaration
public TFluentType Add<T>(T option)
    where T : TOptionTypeParameters
| Type | Name | Description | 
|---|---|---|
| T | option | The option instance | 
Returns
| Type | Description | 
|---|---|
| TFluentType | The option container | 
Type Parameters
| Name | Description | 
|---|---|
| T | The type of option | 
Remarks
It will throw if the item already exist, use Set<T>(T) to overwrite.
Get<T>()
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Get an option of specified type or default(T) if option does not exist
Declaration
public T Get<T>()Returns
| Type | Description | 
|---|---|
| T | The option of specified type or default(T) if option does not exist | 
Type Parameters
| Name | Description | 
|---|---|
| T | The type of option | 
Set<T>(T)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Sets a new option
Declaration
public TFluentType Set<T>(T option)
    where T : TOptionTypeParameters
| Type | Name | Description | 
|---|---|---|
| T | option | The option instance | 
Returns
| Type | Description | 
|---|---|
| TFluentType | The option container | 
Type Parameters
| Name | Description | 
|---|---|
| T | The type of option | 
Remarks
If an option alreay exist of same type it will be overwritten
Setup<T>(Action<T>)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Setup a property on a option
Declaration
public TFluentType Setup<T>(Action<T> action)
    where T : TOptionType, new()Parameters
| Type | Name | Description | 
|---|---|---|
| System.Action<T> | action | The action that configures the option | 
Returns
| Type | Description | 
|---|---|
| TFluentType | The option container | 
Type Parameters
| Name | Description | 
|---|---|
| T | The type of option | 
Remarks
If an option alreay exist of same type it will not be overwritten
Explicit Interface Implementations
IEnumerable<TOptionType>.GetEnumerator()
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice.
Declaration
IEnumerator<TOptionType> IEnumerable<TOptionType>.GetEnumerator()Returns
| Type | Description | 
|---|---|
| System.Collections.Generic.IEnumerator<TOptionType> | 
IEnumerable.GetEnumerator()
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice.
Declaration
IEnumerator IEnumerable.GetEnumerator()Returns
| Type | Description | 
|---|---|
| System.Collections.IEnumerator | 
