コード例 #1
0
        public async Task <ReadAllPage> ReadAllBackwards(
            long fromPositionInclusive,
            int maxCount,
            bool prefetchJsonData = true,
            CancellationToken cancellationToken = default)
        {
            var client = CreateClient();

            client = await client.RootAsync(
                LinkFormatter.ReadAllBackwards(fromPositionInclusive, maxCount, prefetchJsonData),
                cancellationToken);

            return(ReadAllBackwardsInternal(client, prefetchJsonData));
        }
コード例 #2
0
        public async Task <ReadAllPage> ReadAllBackwards(
            long fromPositionInclusive,
            int maxCount,
            bool prefetchJsonData = true,
            CancellationToken cancellationToken = default)
        {
            Ensure.That(fromPositionInclusive, nameof(fromPositionInclusive)).IsGte(-1);
            Ensure.That(maxCount, nameof(maxCount)).IsGte(1);

            GuardAgainstDisposed();

            var client = CreateClient();

            client = await client.RootAsync(
                LinkFormatter.ReadAllBackwards(fromPositionInclusive, maxCount, prefetchJsonData),
                cancellationToken);

            return(ReadAllBackwardsInternal(client, prefetchJsonData));
        }