예제 #1
0
        private static async Task<Stream> ReceiveData(TransferHandle state, ICompressionProvider compression)
        {
            var context = await new AsyncSocketWriterReader(state.ClientSocket, state.BufferSize)
                .ReadAsync();

            return compression.DecompressFrom(context.ReceivedData);
        }