示例#1
0
 /// <summary>
 /// Construct a TimedStream
 /// </summary>
 /// <param name="baseStream"> Undelying stream</param>
 public TimedStream(Stream baseStream)
 {
     this._baseStream = baseStream;
     _timeout         = baseStream.CanTimeout ? baseStream.ReadTimeout : System.Threading.Timeout.Infinite;
     IsClosed         = false;
     _stopwatch       = new LowResolutionStopwatch();
 }
 /// <summary>
 /// Construct a TimedStream
 /// </summary>
 /// <param name="baseStream"> Undelying stream</param>
 public TimedStream(Stream baseStream)
 {
     this.baseStream = baseStream;
     timeout         = baseStream.ReadTimeout;
     isClosed        = false;
     stopwatch       = new LowResolutionStopwatch();
 }
示例#3
0
        /// <summary>
        /// Construct a TimedStream
        /// </summary>
        /// <param name="baseStream"> Undelying stream</param>
        public TimedStream(Stream baseStream)
        {
            this.baseStream = baseStream;
#if !CF && !RT
            timeout = baseStream.ReadTimeout;
#else
            timeout = System.Threading.Timeout.Infinite;
#endif
            isClosed  = false;
            stopwatch = new LowResolutionStopwatch();
        }