-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0c65adf
commit 644fc43
Showing
13 changed files
with
367 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
using System; | ||
using System.Linq.Expressions; | ||
using CouchDB.Driver.Types; | ||
|
||
namespace CouchDB.Driver.Indexes | ||
{ | ||
public interface IIndexBuilder<TSource> | ||
where TSource : CouchDocument | ||
{ | ||
IMultiFieldIndexBuilder<TSource> IndexBy<TSelector>(Expression<Func<TSource, TSelector>> selector); | ||
} | ||
|
||
public interface IMultiFieldIndexBuilder<TSource> : IIndexBuilder<TSource> | ||
where TSource : CouchDocument | ||
{ | ||
IMultiFieldIndexBuilder<TSource> AlsoBy<TSelector>(Expression<Func<TSource, TSelector>> selector); | ||
IMultiFieldIndexBuilder<TSource> Where(Expression<Func<TSource, bool>> selector); | ||
IOrderedIndexBuilder<TSource> OrderBy<TSelector>(Expression<Func<TSource, TSelector>> selector); | ||
IOrderedDescendingIndexBuilder<TSource> OrderByDescending<TSelector>(Expression<Func<TSource, TSelector>> selector); | ||
IMultiFieldIndexBuilder<TSource> Take(int take); | ||
IMultiFieldIndexBuilder<TSource> Skip(int skip); | ||
} | ||
|
||
public interface IOrderedIndexBuilder<TSource> : IMultiFieldIndexBuilder<TSource> | ||
where TSource : CouchDocument | ||
{ | ||
IOrderedIndexBuilder<TSource> ThenBy<TSelector>(Expression<Func<TSource, TSelector>> selector); | ||
} | ||
|
||
public interface IOrderedDescendingIndexBuilder<TSource> : IMultiFieldIndexBuilder<TSource> | ||
where TSource : CouchDocument | ||
{ | ||
IOrderedDescendingIndexBuilder<TSource> ThenByDescending<TSelector>(Expression<Func<TSource, TSelector>> selector); | ||
} | ||
} |
Oops, something went wrong.