// Not using the localStream because this is the request-reply operation. public Stream DownloadStream() { log.Add("DownloadStream"); FlowControlledStream stream = new FlowControlledStream(); stream.StreamDuration = TimeSpan.FromSeconds(1); stream.ReadThrottle = TimeSpan.FromMilliseconds(500); return stream; }
// Not using the localStream because this is the request-reply operation. public Stream DownloadStream() { log.Add("DownloadStream"); FlowControlledStream stream = new FlowControlledStream(); stream.StreamDuration = TimeSpan.FromSeconds(1); stream.ReadThrottle = TimeSpan.FromMilliseconds(500); return(stream); }
void PushStream(object state) { IPushCallback pushCallbackChannel = state as IPushCallback; localStream = new FlowControlledStream(); localStream.ReadThrottle = TimeSpan.FromMilliseconds(800); pushCallbackChannel.ReceiveStream(localStream); }
public Stream DownloadCustomizedStream(TimeSpan readThrottle, TimeSpan streamDuration) { s_log.Add("DownloadStream"); _localStream = new FlowControlledStream(); _localStream.ReadThrottle = readThrottle; _localStream.StreamDuration = streamDuration; return(_localStream); }
void PushStreamLongwait(object state) { IPushCallback pushCallbackChannel = state as IPushCallback; localStream = new FlowControlledStream(); localStream.ReadThrottle = TimeSpan.FromMilliseconds(3000); localStream.StreamDuration = TimeSpan.FromSeconds(2); try { pushCallbackChannel.ReceiveStreamWithException(localStream); } catch (Exception ex) { Console.WriteLine(String.Format("Server got the following exception: {0}", ex)); this.exceptionstring = ex.GetType().Name; } }
public Stream DownloadCustomizedStream(TimeSpan readThrottle, TimeSpan streamDuration) { log.Add("DownloadStream"); localStream = new FlowControlledStream(); localStream.ReadThrottle = readThrottle; localStream.StreamDuration = streamDuration; return localStream; }