Class OrderedServiceCollection<TService, TServiceMetadata>
Collection of ordered services.
Inheritance
System.Object
OrderedServiceCollection<TService, TServiceMetadata>
Implements
IOrderedServiceCollection<TService, TServiceMetadata>
System.Collections.Generic.IEnumerable<IExportFactory<TService, TServiceMetadata>>
System.Collections.IEnumerable
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Kephas.Services
Assembly: Kephas.Core.dll
Syntax
[OverridePriority(Priority.Low)]
public class OrderedServiceCollection<TService, TServiceMetadata> : IOrderedServiceCollection<TService, TServiceMetadata>, IEnumerable<IExportFactory<TService, TServiceMetadata>>, IEnumerable where TServiceMetadata : AppServiceMetadata
Type Parameters
Name | Description |
---|---|
TService | Type of the service. |
TServiceMetadata | Type of the service metadata. |
Constructors
| Improve this Doc View SourceOrderedServiceCollection(IEnumerable<IExportFactory<TService, TServiceMetadata>>)
Initializes a new instance of the OrderedServiceCollection<TService, TServiceMetadata> class.
Declaration
public OrderedServiceCollection(IEnumerable<IExportFactory<TService, TServiceMetadata>> serviceFactories = null)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.IEnumerable<IExportFactory<TService, TServiceMetadata>> | serviceFactories | The service factories. |
Methods
| Improve this Doc View SourceGetEnumerator()
Gets the enumerator.
Declaration
public IEnumerator<IExportFactory<TService, TServiceMetadata>> GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerator<IExportFactory<TService, TServiceMetadata>> | The enumerator. |
GetServiceFactories(Func<IExportFactory<TService, TServiceMetadata>, Boolean>)
Gets the service factories in the appropriate order.
Declaration
public IEnumerable<IExportFactory<TService, TServiceMetadata>> GetServiceFactories(Func<IExportFactory<TService, TServiceMetadata>, bool> filter = null)
Parameters
Type | Name | Description |
---|---|---|
System.Func<IExportFactory<TService, TServiceMetadata>, System.Boolean> | filter | Optional. Specifies a filter. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<IExportFactory<TService, TServiceMetadata>> | The ordered service factories. |
GetServices(Func<IExportFactory<TService, TServiceMetadata>, Boolean>)
Gets the services in the appropriate order.
Declaration
public IEnumerable<TService> GetServices(Func<IExportFactory<TService, TServiceMetadata>, bool> filter = null)
Parameters
Type | Name | Description |
---|---|---|
System.Func<IExportFactory<TService, TServiceMetadata>, System.Boolean> | filter | Optional. Specifies a filter. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<TService> | The ordered services. |
Explicit Interface Implementations
| Improve this Doc View SourceIEnumerable.GetEnumerator()
Gets the enumerator.
Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.IEnumerator | The enumerator. |
Implements
System.Collections.Generic.IEnumerable<T>
System.Collections.IEnumerable