Line data Source code
1 : #region Copyright
2 : // // -----------------------------------------------------------------------
3 : // // <copyright company="Chinchilla Software Limited">
4 : // // Copyright Chinchilla Software Limited. All rights reserved.
5 : // // </copyright>
6 : // // -----------------------------------------------------------------------
7 : #endregion
8 :
9 : using System;
10 :
11 : namespace Cqrs.Repositories.Queries
12 : {
13 : /// <summary>
14 : /// A query that will produce a result
15 : /// </summary>
16 : /// <typeparam name="TQueryStrategy">The <see cref="Type"/> of the <see cref="IQueryStrategy"/>.</typeparam>
17 : /// <typeparam name="TData">The <see cref="Type"/> of data in the result collection.</typeparam>
18 : public class ResultQuery<TQueryStrategy, TData>
19 : : IQueryWithStrategy<TQueryStrategy>
20 : , IQueryWithResults<TData>
21 : where TQueryStrategy : IQueryStrategy
22 1 : {
23 : /// <summary>
24 : /// The <typeparamref name="TQueryStrategy"/> to be executed and produce a result.
25 : /// </summary>
26 : public TQueryStrategy QueryStrategy { get; set; }
27 :
28 : /// <summary>
29 : /// The resulting of executing the <see cref="QueryStrategy"/>.
30 : /// </summary>
31 : public TData Result { get; set; }
32 : }
33 : }
|