/// <inheritdoc />
 public T FirstOrDefault <T>(string cql, params object[] args)
 {
     return(FirstOrDefault <T>(Cql.New(cql, args, CqlQueryOptions.None)));
 }
 /// <inheritdoc />
 public IPage <T> FetchPage <T>(int pageSize, byte[] pagingState, string cql, params object[] args)
 {
     return(FetchPage <T>(Cql.New(cql, args, new CqlQueryOptions().SetPageSize(pageSize).SetPagingState(pagingState))));
 }
 /// <inheritdoc />
 public T Single <T>(string cql, params object[] args)
 {
     return(Single <T>(Cql.New(cql, args, CqlQueryOptions.None)));
 }
 /// <inheritdoc />
 public Task <IEnumerable <T> > FetchAsync <T>(CqlQueryOptions options = null)
 {
     return(FetchAsync <T>(Cql.New(string.Empty, new object[0], options ?? CqlQueryOptions.None)));
 }
 public void Execute(Cql cql)
 {
     _statements.Add(cql);
 }
 /// <inheritdoc />
 public void Delete <T>(string cql, params object[] args)
 {
     Delete <T>(Cql.New(cql, args, CqlQueryOptions.None));
 }
 /// <inheritdoc />
 public void Execute(string cql, params object[] args)
 {
     Execute(Cql.New(cql, args, CqlQueryOptions.None));
 }
 /// <inheritdoc />
 public Task ExecuteAsync(string cql, params object[] args)
 {
     return(ExecuteAsync(Cql.New(cql, args, CqlQueryOptions.None)));
 }
 /// <inheritdoc />
 public AppliedInfo <T> DeleteIf <T>(Cql cql)
 {
     return(TaskHelper.WaitToComplete(DeleteIfAsync <T>(cql), _queryAbortTimeout));
 }
示例#10
0
 /// <inheritdoc />
 public Task DeleteAsync <T>(string cql, params object[] args)
 {
     return(DeleteAsync <T>(Cql.New(cql, args, CqlQueryOptions.None)));
 }
示例#11
0
 /// <inheritdoc />
 public Task DeleteAsync <T>(Cql cql)
 {
     _cqlGenerator.PrependDelete <T>(cql);
     return(ExecuteAsync(cql));
 }
示例#12
0
 /// <inheritdoc />
 public Task <T> SingleOrDefaultAsync <T>(string cql, params object[] args)
 {
     return(SingleOrDefaultAsync <T>(Cql.New(cql, args, CqlQueryOptions.None)));
 }
示例#13
0
 /// <inheritdoc />
 public Task <IPage <T> > FetchPageAsync <T>(int pageSize, byte[] pagingState, string query, object[] args)
 {
     return(FetchPageAsync <T>(Cql.New(query, args, new CqlQueryOptions().SetPageSize(pageSize).SetPagingState(pagingState))));
 }
示例#14
0
 /// <inheritdoc />
 public Task <IPage <T> > FetchPageAsync <T>(CqlQueryOptions options = null)
 {
     return(FetchPageAsync <T>(Cql.New(string.Empty, new object[0], options ?? new CqlQueryOptions())));
 }
示例#15
0
 /// <inheritdoc />
 public AppliedInfo <T> UpdateIf <T>(string cql, params object[] args)
 {
     return(UpdateIf <T>(Cql.New(cql, args, CqlQueryOptions.None)));
 }
示例#16
0
 /// <inheritdoc />
 public Task <AppliedInfo <T> > DeleteIfAsync <T>(string cql, params object[] args)
 {
     return(DeleteIfAsync <T>(Cql.New(cql, args, CqlQueryOptions.None)));
 }
示例#17
0
 /// <inheritdoc />
 public AppliedInfo <T> UpdateIf <T>(Cql cql)
 {
     //Wait async method to be completed or throw
     return(TaskHelper.WaitToComplete(UpdateIfAsync <T>(cql), _queryAbortTimeout));
 }
示例#18
0
 /// <inheritdoc />
 public Task <AppliedInfo <T> > DeleteIfAsync <T>(Cql cql)
 {
     _cqlGenerator.PrependDelete <T>(cql);
     return(ExecuteAsyncAndAdapt(cql, (stmt, rs) => AppliedInfo <T> .FromRowSet(_mapperFactory, cql.Statement, rs)));
 }
示例#19
0
 /// <inheritdoc />
 public void Delete <T>(Cql cql)
 {
     //Wait async method to be completed or throw
     TaskHelper.WaitToComplete(DeleteAsync <T>(cql), _queryAbortTimeout);
 }
示例#20
0
 /// <inheritdoc />
 public IEnumerable <T> Fetch <T>(CqlQueryOptions queryOptions = null)
 {
     // Just let the SQL be auto-generated
     return(Fetch <T>(Cql.New(string.Empty, new object[0], queryOptions ?? CqlQueryOptions.None)));
 }
示例#21
0
 /// <inheritdoc />
 public void Execute(Cql cql)
 {
     //Wait async method to be completed or throw
     TaskHelper.WaitToComplete(ExecuteAsync(cql), _queryAbortTimeout);
 }
示例#22
0
 /// <inheritdoc />
 public IPage <T> FetchPage <T>(CqlQueryOptions queryOptions = null)
 {
     return(FetchPage <T>(Cql.New(string.Empty, new object[0], queryOptions ?? new CqlQueryOptions())));
 }
示例#23
0
 /// <inheritdoc />
 public Task <IEnumerable <T> > FetchAsync <T>(string cql, params object[] args)
 {
     return(FetchAsync <T>(Cql.New(cql, args, CqlQueryOptions.None)));
 }
 public void Delete <T>(Cql cql)
 {
     _cqlGenerator.PrependDelete <T>(cql);
     _statements.Add(cql);
 }