2using System.Collections;
3using System.Collections.Generic;
4using System.Threading.Tasks;
13 internal class EmptyCursor<T> : ICursor<T>
18 internal EmptyCursor()
27 public T Current =>
throw new InvalidOperationException(
"Enumeration not started. Call MoveNext() first.");
32 public IObjectSerializer CurrentSerializer =>
throw new InvalidOperationException(
"Enumeration not started. Call MoveNext() first.");
38 public bool CurrentTypeCompatible =>
false;
54 object IEnumerator.Current => this.Current;
63 public bool MoveNext() => this.MoveNextAsyncLocked().Result;
77 public Guid CurrentObjectId =>
throw new InvalidOperationException(
"Enumeration not started. Call MoveNext() first.");
92 public Task<bool> MoveNextAsyncLocked()
94 return Task.FromResult(
false);
103 public Task<bool> MovePreviousAsyncLocked()
105 return Task.FromResult(
false);
108 public IEnumerator<T> GetEnumerator()
111 return (IEnumerator<T>)A.GetEnumerator();
121 public bool SameSortOrder(
string[] ConstantFields,
string[] SortOrder)
133 public bool ReverseSortOrder(
string[] ConstantFields,
string[] SortOrder)
142 public Task ContinueAfterLocked(T LastItem)
144 return Task.CompletedTask;
151 public Task ContinueBeforeLocked(T LastItem)
153 return Task.CompletedTask;
Interface for asynchronous enumerators.
Task< bool > MoveNextAsync()
Advances the enumerator to the next element of the collection.
Interface for object serializers.