public sealed class AsyncStreamAdapter<T> : IAsyncStreamReader<T>
Simple adapter to allow an IAsyncEnumerator<T> to be used as a gRPC IAsyncStreamReader<T>.
Note that cancellation is not fully supported, due to differences between the two interfaces.
Task containing the result of the operation: true if the reader was successfully advanced
to the next element; false if the reader has passed the end of the sequence.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThe latest version of \u003ccode\u003eAsyncStreamAdapter\u003c/code\u003e is 4.10.0, with multiple earlier versions available, going back to version 3.2.0.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eAsyncStreamAdapter<T>\u003c/code\u003e is a class that adapts an \u003ccode\u003eIAsyncEnumerator<T>\u003c/code\u003e to function as a gRPC \u003ccode\u003eIAsyncStreamReader<T>\u003c/code\u003e, enabling their interoperability.\u003c/p\u003e\n"],["\u003cp\u003eThe class includes a constructor that wraps an \u003ccode\u003eIAsyncEnumerator<T>\u003c/code\u003e to be used as an async stream reader.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eMoveNext\u003c/code\u003e method advances the reader asynchronously to the next element, using a \u003ccode\u003eCancellationToken\u003c/code\u003e for optional cancellation, and returns \u003ccode\u003etrue\u003c/code\u003e if successful, or \u003ccode\u003efalse\u003c/code\u003e if it reaches the end of the sequence.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eCurrent\u003c/code\u003e property is a getter for the current item in the stream, of type \u003ccode\u003eT\u003c/code\u003e.\u003c/p\u003e\n"]]],[],null,[]]