Class DefaultClientQueryExecutor
Base class for client query executors.
Inheritance
Implements
Inherited Members
Namespace: Kephas.Data.Client.Queries
Assembly: Kephas.Data.Client.dll
Syntax
[OverridePriority(Priority.Low)]
public class DefaultClientQueryExecutor : IClientQueryExecutor
Constructors
| Improve this Doc View SourceDefaultClientQueryExecutor(IClientQueryConverter, IDataConversionService, ITypeResolver, IProjectedTypeResolver, IExportFactory<IDataSpace>)
Initializes a new instance of the DefaultClientQueryExecutor class.
Declaration
public DefaultClientQueryExecutor(IClientQueryConverter clientQueryConverter, IDataConversionService conversionService, ITypeResolver typeResolver, IProjectedTypeResolver projectedTypeResolver, IExportFactory<IDataSpace> dataSpaceFactory)
Parameters
Type | Name | Description |
---|---|---|
IClientQueryConverter | clientQueryConverter | The client query converter. |
IDataConversionService | conversionService | The conversion service. |
ITypeResolver | typeResolver | The type resolver. |
IProjectedTypeResolver | projectedTypeResolver | The projected type resolver. |
IExportFactory<IDataSpace> | dataSpaceFactory | The data space factory. |
Properties
| Improve this Doc View SourceClientQueryConverter
Gets the client query converter.
Declaration
public IClientQueryConverter ClientQueryConverter { get; }
Property Value
Type | Description |
---|---|
IClientQueryConverter | The client query converter. |
ConversionService
Gets the conversion service.
Declaration
public IDataConversionService ConversionService { get; }
Property Value
Type | Description |
---|---|
IDataConversionService | The conversion service. |
DataSpaceFactory
Gets the data space factory.
Declaration
public IExportFactory<IDataSpace> DataSpaceFactory { get; }
Property Value
Type | Description |
---|---|
IExportFactory<IDataSpace> |
ProjectedTypeResolver
Gets the projected type resolver.
Declaration
public IProjectedTypeResolver ProjectedTypeResolver { get; }
Property Value
Type | Description |
---|---|
IProjectedTypeResolver | The projected type resolver. |
TypeResolver
Gets the type resolver.
Declaration
public ITypeResolver TypeResolver { get; }
Property Value
Type | Description |
---|---|
ITypeResolver | The type resolver. |
Methods
| Improve this Doc View SourceExecuteQueryAsync(ClientQuery, IClientQueryExecutionContext, CancellationToken)
Executes the query asynchronously.
Declaration
public Task<IList<object>> ExecuteQueryAsync(ClientQuery query, IClientQueryExecutionContext executionContext = null, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
ClientQuery | query | The query. |
IClientQueryExecutionContext | executionContext | Context for the execution (optional). |
System.Threading.CancellationToken | cancellationToken | The cancellation token (optional). |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Collections.Generic.IList<System.Object>> | A list of client entities. |
ExecuteQueryAsync<TClientEntity, TEntity>(ClientQuery, IClientQueryExecutionContext, CancellationToken)
Executes the query operation.
Declaration
protected virtual Task<IList<object>> ExecuteQueryAsync<TClientEntity, TEntity>(ClientQuery clientQuery, IClientQueryExecutionContext executionContext, CancellationToken token)
where TClientEntity : class where TEntity : class
Parameters
Type | Name | Description |
---|---|---|
ClientQuery | clientQuery | The client query. |
IClientQueryExecutionContext | executionContext | Context for the execution. |
System.Threading.CancellationToken | token | The cancellation token. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Collections.Generic.IList<System.Object>> | A list of. |
Type Parameters
Name | Description |
---|---|
TClientEntity | Type of the client entity. |
TEntity | Type of the entity. |
ResolveEntityType(Type)
Resolves the entity type based on its client counterpart.
Declaration
protected virtual Type ResolveEntityType(Type clientEntityType)
Parameters
Type | Name | Description |
---|---|---|
System.Type | clientEntityType | Type of the client entity. |
Returns
Type | Description |
---|---|
System.Type | A type representing the entity type. |