public long GetCountFor(string id) { var operation = new GetRevisionsCountOperation(id); var command = operation.CreateRequest(); RequestExecutor.Execute(command, Context, sessionInfo: SessionInfo); return(command.Result); }
public async Task <long> GetCountForAsync(string id, CancellationToken token = default) { using (Session.AsyncTaskHolder()) { var operation = new GetRevisionsCountOperation(id); var command = operation.CreateRequest(); await RequestExecutor.ExecuteAsync(command, Context, sessionInfo : SessionInfo, token : token).ConfigureAwait(false); return(command.Result); } }