Read-only stream that presents a windowed view of another stream.
More...
|
| override int | Read (byte[] buffer, int offset, int count) |
| |
| override void | Flush () |
| |
| override long | Seek (long offset, SeekOrigin origin) |
| |
| override void | SetLength (long value) |
| |
| override void | Write (byte[] buffer, int offset, int count) |
| |
|
| override void | Dispose (bool disposing) |
| |
Read-only stream that presents a windowed view of another stream.
Definition at line 33 of file SkipStream.cs.
◆ Dispose()
| override void IKVM.Reflection.Writer.SkipStream.Dispose |
( |
bool | disposing | ) |
|
|
protected |
Definition at line 106 of file SkipStream.cs.
107 {
108 if (disposing)
109 stream.Dispose();
110 }
◆ Flush()
| override void IKVM.Reflection.Writer.SkipStream.Flush |
( |
| ) |
|
◆ Read()
| override int IKVM.Reflection.Writer.SkipStream.Read |
( |
byte[] | buffer, |
|
|
int | offset, |
|
|
int | count ) |
Definition at line 66 of file SkipStream.cs.
67 {
68 if (skipLength != 0 && skipOffset < count)
69 {
70 if (skipOffset != 0)
71 {
72 count = (int)skipOffset;
73 }
74 else
75 {
76
77 while (skipLength != 0)
78 {
79
80 skipLength -= stream.Read(buffer, offset, (int)Math.Min(count, skipLength));
81 }
82 }
83 }
84
85 var totalBytesRead = stream.Read(buffer, offset, count);
86 skipOffset -= totalBytesRead;
87 return totalBytesRead;
88 }
◆ Seek()
| override long IKVM.Reflection.Writer.SkipStream.Seek |
( |
long | offset, |
|
|
SeekOrigin | origin ) |
◆ SetLength()
| override void IKVM.Reflection.Writer.SkipStream.SetLength |
( |
long | value | ) |
|
◆ Write()
| override void IKVM.Reflection.Writer.SkipStream.Write |
( |
byte[] | buffer, |
|
|
int | offset, |
|
|
int | count ) |
◆ CanRead
| override bool IKVM.Reflection.Writer.SkipStream.CanRead |
|
get |
◆ CanSeek
| override bool IKVM.Reflection.Writer.SkipStream.CanSeek |
|
get |
◆ CanWrite
| override bool IKVM.Reflection.Writer.SkipStream.CanWrite |
|
get |
◆ Length
| override long IKVM.Reflection.Writer.SkipStream.Length |
|
get |
◆ Position
| override long IKVM.Reflection.Writer.SkipStream.Position |
|
getset |
Definition at line 92 of file SkipStream.cs.
93 {
94 get => throw new NotSupportedException();
95 set => throw new NotSupportedException();
96 }
The documentation for this class was generated from the following file: