public virtual Task <FacetedQueryResult> GetFacetsAsync(List <Facet> facets, int start, int?pageSize, CancellationToken token = default(CancellationToken)) { var q = GetIndexQuery(); var query = FacetQuery.Create(indexName, q, null, facets, start, pageSize); return(asyncDatabaseCommands.GetFacetsAsync(query, token)); }
public virtual FacetedQueryResult GetFacets(List <Facet> facets, int start, int?pageSize) { var q = GetIndexQuery(false); var query = FacetQuery.Create(indexName, q, null, facets, start, pageSize); return(databaseCommands.GetFacets(query)); }
/// <inheritdoc /> public Lazy <FacetedQueryResult> GetFacetsLazy(List <Facet> facets, int facetStart, int?facetPageSize) { var q = GetIndexQuery(); var query = FacetQuery.Create(q, null, facets, facetStart, facetPageSize, Conventions); var lazyFacetsOperation = new LazyFacetsOperation(Conventions, query); return(((DocumentSession)TheSession).AddLazyOperation(lazyFacetsOperation, (Action <FacetedQueryResult>)null)); }
public virtual FacetedQueryResult GetFacets(List <Facet> facets, int start, int?pageSize) { var q = GetIndexQuery(false); var query = FacetQuery.Create(q, null, facets, start, pageSize, Session.Conventions); var command = new GetFacetsCommand(_session.Conventions, _session.Context, query); _session.RequestExecutor.Execute(command, _session.Context); return(command.Result); }
public virtual Task <FacetedQueryResult> GetFacetsAsync(string facetSetupDoc, int start, int?pageSize, CancellationToken token = default(CancellationToken)) { var q = GetIndexQuery(); var query = FacetQuery.Create(indexName, q, facetSetupDoc, null, start, pageSize); // TODO iftah return(null); //return asyncDatabaseCommands.GetFacetsAsync(query, token); }
public virtual FacetedQueryResult GetFacets(string facetSetupDoc, int start, int?pageSize) { var q = GetIndexQuery(false); var query = FacetQuery.Create(indexName, q, facetSetupDoc, null, start, pageSize); // TODO iftah return(null); //return databaseCommands.GetFacets(query); }
/// <inheritdoc /> public Lazy <Task <FacetedQueryResult> > GetFacetsLazyAsync(List <Facet> facets, int facetStart, int?facetPageSize, CancellationToken token = default(CancellationToken)) { var q = GetIndexQuery(); var query = FacetQuery.Create(q, null, facets, facetStart, facetPageSize, Conventions); var lazyFacetsOperation = new LazyFacetsOperation(Conventions, query); return(((AsyncDocumentSession)TheSession).AddLazyOperation <FacetedQueryResult>(lazyFacetsOperation, null, token)); }
public virtual async Task <FacetedQueryResult> GetFacetsAsync(List <Facet> facets, int start, int?pageSize, CancellationToken token = default(CancellationToken)) { var q = GetIndexQuery(); var query = FacetQuery.Create(q, null, facets, start, pageSize, Session.Conventions); var command = new GetFacetsCommand(_session.Conventions, _session.Context, query); await _session.RequestExecutor.ExecuteAsync(command, _session.Context, token).ConfigureAwait(false); return(command.Result); }
/// <inheritdoc /> public async Task <FacetedQueryResult> GetFacetsAsync(string facetSetupDoc, int facetStart, int?facetPageSize, CancellationToken token = default(CancellationToken)) { var q = GetIndexQuery(); var query = FacetQuery.Create(q, facetSetupDoc, null, facetStart, facetPageSize, Conventions); var command = new GetFacetsCommand(Conventions, TheSession.Context, query); await TheSession.RequestExecutor.ExecuteAsync(command, TheSession.Context, token).ConfigureAwait(false); return(command.Result); }
/// <inheritdoc /> public FacetedQueryResult GetFacets(List <Facet> facets, int facetStart, int?facetPageSize) { var q = GetIndexQuery(); var query = FacetQuery.Create(q, null, facets, facetStart, facetPageSize, Conventions); var command = new GetFacetsCommand(Conventions, TheSession.Context, query); TheSession.RequestExecutor.Execute(command, TheSession.Context); return(command.Result); }
public override async Task <FacetedQueryResult> GetFacetsAsync(string facetSetupDoc, int start, int?pageSize, CancellationToken token = default(CancellationToken)) { var indexQuery = GetIndexQuery(true); var results = await shardStrategy.ShardAccessStrategy.ApplyAsync(asyncShardDbCommands, new ShardRequestData { IndexName = AsyncIndexQueried, EntityType = typeof(T), Query = indexQuery }, (commands, i) => { var query = FacetQuery.Create(AsyncIndexQueried, indexQuery, facetSetupDoc, null, start, pageSize); return(commands.GetFacetsAsync(query, token)); }).ConfigureAwait(false); return(MergeFacets(results)); }
public override FacetedQueryResult GetFacets(List <Facet> facets, int start, int?pageSize) { var indexQuery = GetIndexQuery(false); var results = shardStrategy.ShardAccessStrategy.Apply(shardDbCommands, new ShardRequestData { IndexName = IndexQueried, EntityType = typeof(T), Query = indexQuery }, (commands, i) => { var query = FacetQuery.Create(IndexQueried, indexQuery, null, facets, start, pageSize); return(commands.GetFacets(query)); }); return(MergeFacets(results)); }