示例#1
0
        public override int ReadByte()
        {
            if (!_listener.AskContinue())
            {
                Commit();
                throw new ProgressInterruptedException("ProgreesReportingInputStream: ReadByte has been interrupted.");
            }

            int data = _stream.ReadByte();

            if (data != -1)
            {
                Notify(1);
            }
            else
            {
                Commit();
            }

            return(data);
        }