terraria-cpp2il-methodrecon v1.4.4.9
Terraria mobile dump, with reconstructed method body. Dump with CallAnalysis: https://infinitynichto.github.io/terraria-cpp2il
Loading...
Searching...
No Matches
Stream.cs
Go to the documentation of this file.
1using System;
9
10namespace System.IO
11{
12 // Token: 0x02000557 RID: 1367
14 public abstract class Stream : MarshalByRefObject, IDisposable
15 {
16 // Token: 0x060028A3 RID: 10403 RVA: 0x00058514 File Offset: 0x00056714
18 {
19 int num = 1;
20 if (num == 0)
21 {
22 }
23 if (num == 0)
24 {
25 }
27 return semaphoreSlim;
28 }
29
30 // Token: 0x170005E0 RID: 1504
31 // (get) Token: 0x060028A4 RID: 10404
32 public abstract bool CanRead { get; }
33
34 // Token: 0x170005E1 RID: 1505
35 // (get) Token: 0x060028A5 RID: 10405
36 public abstract bool CanSeek { get; }
37
38 // Token: 0x170005E2 RID: 1506
39 // (get) Token: 0x060028A6 RID: 10406 RVA: 0x0005852C File Offset: 0x0005672C
40 public virtual bool CanTimeout
41 {
42 get
43 {
44 }
45 }
46
47 // Token: 0x170005E3 RID: 1507
48 // (get) Token: 0x060028A7 RID: 10407
49 public abstract bool CanWrite { get; }
50
51 // Token: 0x170005E4 RID: 1508
52 // (get) Token: 0x060028A8 RID: 10408
53 public abstract long Length { get; }
54
55 // Token: 0x170005E5 RID: 1509
56 // (get) Token: 0x060028A9 RID: 10409
57 // (set) Token: 0x060028AA RID: 10410
58 public abstract long Position { get; set; }
59
60 // Token: 0x170005E6 RID: 1510
61 // (get) Token: 0x060028AB RID: 10411 RVA: 0x0000207A File Offset: 0x0000027A
62 // (set) Token: 0x060028AC RID: 10412 RVA: 0x0000207A File Offset: 0x0000027A
63 public virtual int ReadTimeout
64 {
65 get
66 {
67 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
68 }
69 set
70 {
71 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
72 }
73 }
74
75 // Token: 0x170005E7 RID: 1511
76 // (get) Token: 0x060028AD RID: 10413 RVA: 0x0000207A File Offset: 0x0000027A
77 // (set) Token: 0x060028AE RID: 10414 RVA: 0x0000207A File Offset: 0x0000027A
78 public virtual int WriteTimeout
79 {
80 get
81 {
82 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
83 }
84 set
85 {
86 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
87 }
88 }
89
90 // Token: 0x060028AF RID: 10415 RVA: 0x0005853C File Offset: 0x0005673C
92 {
94 }
95
96 // Token: 0x060028B0 RID: 10416 RVA: 0x00058550 File Offset: 0x00056750
97 public virtual void CopyTo(Stream destination, int bufferSize)
98 {
100 if (!true)
101 {
102 }
103 if (!true)
104 {
105 }
106 if (this != null)
107 {
108 return;
109 }
110 }
111
112 // Token: 0x060028B1 RID: 10417 RVA: 0x00058570 File Offset: 0x00056770
113 private int GetCopyBufferSize()
114 {
115 return 1;
116 }
117
118 // Token: 0x060028B2 RID: 10418 RVA: 0x00058580 File Offset: 0x00056780
119 public virtual void Close()
120 {
121 GC.SuppressFinalize(this);
122 }
123
124 // Token: 0x060028B3 RID: 10419 RVA: 0x00058594 File Offset: 0x00056794
125 public void Dispose()
126 {
127 }
128
129 // Token: 0x060028B4 RID: 10420 RVA: 0x000585A4 File Offset: 0x000567A4
130 protected virtual void Dispose(bool disposing)
131 {
132 }
133
134 // Token: 0x060028B5 RID: 10421
135 public abstract void Flush();
136
137 // Token: 0x060028B6 RID: 10422 RVA: 0x000585B4 File Offset: 0x000567B4
138 public virtual Task FlushAsync(CancellationToken cancellationToken)
139 {
140 if (!true)
141 {
142 }
143 if (!true)
144 {
145 }
146 Task task;
147 return task;
148 }
149
150 // Token: 0x060028B7 RID: 10423 RVA: 0x000585C8 File Offset: 0x000567C8
151 public virtual IAsyncResult BeginRead(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
152 {
153 long num = 0L;
154 return this.BeginReadInternal(buffer, offset, count, callback, state, num != 0L, true);
155 }
156
157 // Token: 0x060028B8 RID: 10424 RVA: 0x000585E8 File Offset: 0x000567E8
158 internal IAsyncResult BeginReadInternal(byte[] buffer, int offset, int count, AsyncCallback callback, object state, bool serializeAsynchronously, bool apm)
159 {
160 /*
161An exception occurred when decompiling this method (060028B8)
162
163ICSharpCode.Decompiler.DecompilerException: Error decompiling System.IAsyncResult System.IO.Stream::BeginReadInternal(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object,System.Boolean,System.Boolean)
164
165 ---> System.Exception: Basic block has to end with unconditional control flow.
166{
167 IL_0015:
168 stloc:Exception(var_2_1A, call:Exception(Error::GetReadNotSupported))
169}
170
171 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
172 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
173 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
174 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
175 --- End of inner exception stack trace ---
176 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
177 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
178*/;
179 }
180
181 // Token: 0x060028B9 RID: 10425 RVA: 0x00058610 File Offset: 0x00056810
182 public virtual int EndRead(IAsyncResult asyncResult)
183 {
184 if (asyncResult != null)
185 {
187 if (activeReadWriteTask != null)
188 {
189 bool isRead = activeReadWriteTask._isRead;
190 long num = 0L;
192 if (num == 0L)
193 {
194 }
195 }
196 }
197 throw new OutOfMemoryException();
198 }
199
200 // Token: 0x060028BA RID: 10426 RVA: 0x00058650 File Offset: 0x00056850
201 public Task<int> ReadAsync(byte[] buffer, int offset, int count)
202 {
203 /*
204An exception occurred when decompiling this method (060028BA)
205
206ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Threading.Tasks.Task`1<System.Int32> System.IO.Stream::ReadAsync(System.Byte[],System.Int32,System.Int32)
207
208 ---> System.Exception: Basic block has to end with unconditional control flow.
209{
210 IL_0003:
211 stloc:CancellationToken(var_1_0A, callgetter:CancellationToken(CancellationToken::get_None))
212}
213
214 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
215 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
216 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
217 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
218 --- End of inner exception stack trace ---
219 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
220 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
221*/;
222 }
223
224 // Token: 0x060028BB RID: 10427 RVA: 0x00058668 File Offset: 0x00056868
225 public virtual Task<int> ReadAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
226 {
227 Task task;
228 return task;
229 }
230
231 // Token: 0x060028BC RID: 10428 RVA: 0x00058678 File Offset: 0x00056878
232 public virtual ValueTask<int> ReadAsync(Memory<byte> buffer, [Optional] CancellationToken cancellationToken)
233 {
235 if (this == null)
236 {
238 }
239 return 38;
240 }
241
242 // Token: 0x060028BD RID: 10429 RVA: 0x0005869C File Offset: 0x0005689C
243 private Task<int> BeginEndReadAsync(byte[] buffer, int offset, int count)
244 {
245 if (!true)
246 {
247 }
248 if (!true)
249 {
250 }
251 if (!true)
252 {
253 }
254 if (count != 0 || !true)
255 {
256 }
257 Task task;
258 return task;
259 }
260
261 // Token: 0x060028BE RID: 10430 RVA: 0x000586BC File Offset: 0x000568BC
262 public virtual IAsyncResult BeginWrite(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
263 {
264 long num = 0L;
265 return this.BeginWriteInternal(buffer, offset, count, callback, state, num != 0L, true);
266 }
267
268 // Token: 0x060028BF RID: 10431 RVA: 0x000586DC File Offset: 0x000568DC
269 internal IAsyncResult BeginWriteInternal(byte[] buffer, int offset, int count, AsyncCallback callback, object state, bool serializeAsynchronously, bool apm)
270 {
271 /*
272An exception occurred when decompiling this method (060028BF)
273
274ICSharpCode.Decompiler.DecompilerException: Error decompiling System.IAsyncResult System.IO.Stream::BeginWriteInternal(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object,System.Boolean,System.Boolean)
275
276 ---> System.Exception: Basic block has to end with unconditional control flow.
277{
278 IL_0015:
279 stloc:Exception(var_2_1A, call:Exception(Error::GetWriteNotSupported))
280}
281
282 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
283 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
284 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
285 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
286 --- End of inner exception stack trace ---
287 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
288 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
289*/;
290 }
291
292 // Token: 0x060028C0 RID: 10432 RVA: 0x00058704 File Offset: 0x00056904
294 {
295 bool isCompleted = asyncWaiter.IsCompleted;
297 }
298
299 // Token: 0x060028C1 RID: 10433 RVA: 0x00058728 File Offset: 0x00056928
301 {
303 if (!true)
304 {
305 }
306 if (!true)
307 {
308 }
309 long num = 0L;
311 readWriteTask.ScheduleAndStart(num != 0L);
312 }
313
314 // Token: 0x060028C2 RID: 10434 RVA: 0x00058754 File Offset: 0x00056954
316 {
317 int num = this._asyncActiveSemaphore.Release();
318 }
319
320 // Token: 0x060028C3 RID: 10435 RVA: 0x00058770 File Offset: 0x00056970
321 public virtual void EndWrite(IAsyncResult asyncResult)
322 {
323 if (asyncResult == null)
324 {
325 return;
326 }
328 if (activeReadWriteTask == null || activeReadWriteTask._isRead)
329 {
330 return;
331 }
332 long num = 0L;
334 if (num == 0L)
335 {
336 return;
337 }
338 throw new OutOfMemoryException();
339 }
340
341 // Token: 0x060028C4 RID: 10436 RVA: 0x000587BC File Offset: 0x000569BC
342 public Task WriteAsync(byte[] buffer, int offset, int count)
343 {
344 /*
345An exception occurred when decompiling this method (060028C4)
346
347ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Threading.Tasks.Task System.IO.Stream::WriteAsync(System.Byte[],System.Int32,System.Int32)
348
349 ---> System.Exception: Basic block has to end with unconditional control flow.
350{
351 IL_0003:
352 stloc:CancellationToken(var_1_0A, callgetter:CancellationToken(CancellationToken::get_None))
353}
354
355 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
356 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
357 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
358 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
359 --- End of inner exception stack trace ---
360 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
361 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
362*/;
363 }
364
365 // Token: 0x060028C5 RID: 10437 RVA: 0x000587D4 File Offset: 0x000569D4
366 public virtual Task WriteAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
367 {
368 Task task;
369 return task;
370 }
371
372 // Token: 0x060028C6 RID: 10438 RVA: 0x000587EC File Offset: 0x000569EC
373 public virtual ValueTask WriteAsync(ReadOnlyMemory<byte> buffer, [Optional] CancellationToken cancellationToken)
374 {
375 /*
376An exception occurred when decompiling this method (060028C6)
377
378ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Threading.Tasks.ValueTask System.IO.Stream::WriteAsync(System.ReadOnlyMemory`1<System.Byte>,System.Threading.CancellationToken)
379
380 ---> System.Exception: Basic block has to end with unconditional control flow.
381{
382 Block_1:
383 call:void(ThrowHelper::ThrowArgumentNullException, ldc.i4:ExceptionArgument(38))
384}
385
386 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
387 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
388 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
389 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
390 --- End of inner exception stack trace ---
391 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
392 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
393*/;
394 }
395
396 // Token: 0x060028C7 RID: 10439 RVA: 0x0005880C File Offset: 0x00056A0C
397 private Task FinishWriteAsync(Task writeTask, byte[] localBuffer)
398 {
399 if (!true)
400 {
401 }
403 Task task;
404 return task;
405 }
406
407 // Token: 0x060028C8 RID: 10440 RVA: 0x00058828 File Offset: 0x00056A28
408 private Task BeginEndWriteAsync(byte[] buffer, int offset, int count)
409 {
410 /*
411An exception occurred when decompiling this method (060028C8)
412
413ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Threading.Tasks.Task System.IO.Stream::BeginEndWriteAsync(System.Byte[],System.Int32,System.Int32)
414
415 ---> System.Exception: Basic block has to end with unconditional control flow.
416{
417 Block_0:
418 brtrue(IL_0000, ldc.i4:bool(1))
419}
420
421 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
422 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
423 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
424 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1846
425 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
426 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
427 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1846
428 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
429 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
430 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
431 --- End of inner exception stack trace ---
432 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
433 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
434*/;
435 }
436
437 // Token: 0x060028C9 RID: 10441
438 public abstract long Seek(long offset, SeekOrigin origin);
439
440 // Token: 0x060028CA RID: 10442
441 public abstract void SetLength(long value);
442
443 // Token: 0x060028CB RID: 10443
444 public abstract int Read(byte[] buffer, int offset, int count);
445
446 // Token: 0x060028CC RID: 10444 RVA: 0x00058844 File Offset: 0x00056A44
447 public virtual int Read(Span<byte> buffer)
448 {
449 /*
450An exception occurred when decompiling this method (060028CC)
451
452ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Int32 System.IO.Stream::Read(System.Span`1<System.Byte>)
453
454 ---> System.Exception: Basic block has to end with unconditional control flow.
455{
456 Block_0:
457 call:void(ThrowHelper::ThrowArgumentOutOfRangeException)
458}
459
460 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
461 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
462 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
463 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
464 --- End of inner exception stack trace ---
465 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
466 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
467*/;
468 }
469
470 // Token: 0x060028CD RID: 10445 RVA: 0x0005886C File Offset: 0x00056A6C
471 public virtual int ReadByte()
472 {
473 /*
474An exception occurred when decompiling this method (060028CD)
475
476ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Int32 System.IO.Stream::ReadByte()
477
478 ---> System.Exception: Basic block has to end with unconditional control flow.
479{
480 IL_0000:
481 brtrue(IL_0000, logicnot:bool(ldloc:Stream[exp:bool](this)))
482}
483
484 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
485 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
486 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
487 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1846
488 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
489 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
490 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
491 --- End of inner exception stack trace ---
492 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
493 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
494*/;
495 }
496
497 // Token: 0x060028CE RID: 10446
498 public abstract void Write(byte[] buffer, int offset, int count);
499
500 // Token: 0x060028CF RID: 10447 RVA: 0x0005887C File Offset: 0x00056A7C
501 public virtual void Write(ReadOnlySpan<byte> buffer)
502 {
503 if (!true)
504 {
505 }
506 if (!true)
507 {
508 }
509 }
510
511 // Token: 0x060028D0 RID: 10448 RVA: 0x00058894 File Offset: 0x00056A94
512 public virtual void WriteByte(byte value)
513 {
514 }
515
516 // Token: 0x060028D1 RID: 10449 RVA: 0x000588A4 File Offset: 0x00056AA4
517 internal IAsyncResult BlockingBeginRead(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
518 {
519 if (callback != null)
520 {
521 IntPtr invoke_impl = callback.invoke_impl;
522 IntPtr method_code = callback.method_code;
523 IntPtr method = callback.method;
524 }
525 while (callback != null)
526 {
527 }
528 }
529
530 // Token: 0x060028D2 RID: 10450 RVA: 0x000588D4 File Offset: 0x00056AD4
531 internal static int BlockingEndRead(IAsyncResult asyncResult)
532 {
533 int num;
534 return num;
535 }
536
537 // Token: 0x060028D3 RID: 10451 RVA: 0x000588E4 File Offset: 0x00056AE4
538 internal IAsyncResult BlockingBeginWrite(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
539 {
540 if (callback != null)
541 {
542 IntPtr invoke_impl = callback.invoke_impl;
543 IntPtr method_code = callback.method_code;
544 IntPtr method = callback.method;
545 }
546 while (callback != null)
547 {
548 }
549 }
550
551 // Token: 0x060028D4 RID: 10452 RVA: 0x00058914 File Offset: 0x00056B14
552 internal static void BlockingEndWrite(IAsyncResult asyncResult)
553 {
555 }
556
557 // Token: 0x060028D5 RID: 10453 RVA: 0x00058928 File Offset: 0x00056B28
559 {
560 return true;
561 }
562
563 // Token: 0x060028D6 RID: 10454 RVA: 0x00058938 File Offset: 0x00056B38
565 {
566 return true;
567 }
568
569 // Token: 0x060028D7 RID: 10455 RVA: 0x00058948 File Offset: 0x00056B48
570 protected Stream()
571 {
572 }
573
574 // Token: 0x060028D8 RID: 10456 RVA: 0x0005895C File Offset: 0x00056B5C
575 // Note: this type is marked as 'beforefieldinit'.
576 static Stream()
577 {
578 }
579
580 // Token: 0x060028D9 RID: 10457 RVA: 0x0005896C File Offset: 0x00056B6C
588
589 // Token: 0x040015F2 RID: 5618
590 public static readonly Stream Null;
591
592 // Token: 0x040015F3 RID: 5619
595
596 // Token: 0x040015F4 RID: 5620
599
600 // Token: 0x02000558 RID: 1368
601 private struct ReadWriteParameters
602 {
603 // Token: 0x040015F5 RID: 5621
604 internal byte[] Buffer;
605
606 // Token: 0x040015F6 RID: 5622
607 internal int Offset;
608
609 // Token: 0x040015F7 RID: 5623
610 internal int Count;
611 }
612
613 // Token: 0x02000559 RID: 1369
614 private sealed class ReadWriteTask : Task<int>, ITaskCompletionAction
615 {
616 // Token: 0x060028DA RID: 10458 RVA: 0x00058980 File Offset: 0x00056B80
617 internal void ClearBeginState()
618 {
619 }
620
621 // Token: 0x060028DB RID: 10459 RVA: 0x00058990 File Offset: 0x00056B90
622 public ReadWriteTask(bool isRead, bool apm, Func<object, int> function, object state, Stream stream, byte[] buffer, int offset, int count, AsyncCallback callback)
623 {
624 if (!true)
625 {
626 }
628 this._stream = stream;
629 this._buffer = buffer;
633 base.AddCompletionAction(this);
634 }
635
636 // Token: 0x060028DC RID: 10460 RVA: 0x000589D8 File Offset: 0x00056BD8
637 private static void InvokeAsyncCallback(object completedTask)
638 {
639 if (completedTask != null)
640 {
641 }
642 }
643
644 // Token: 0x060028DD RID: 10461 RVA: 0x000589F0 File Offset: 0x00056BF0
646 {
647 if (this._context != null)
648 {
649 return;
650 }
651 AsyncCallback callback = this._callback;
652 IntPtr invoke_impl = callback.invoke_impl;
653 IntPtr method_code = callback.method_code;
654 IntPtr method = callback.method;
655 }
656
657 // Token: 0x170005E8 RID: 1512
658 // (get) Token: 0x060028DE RID: 10462 RVA: 0x00058A28 File Offset: 0x00056C28
660 {
661 get
662 {
663 return true;
664 }
665 }
666
667 // Token: 0x040015F8 RID: 5624
668 internal readonly bool _isRead;
669
670 // Token: 0x040015F9 RID: 5625
671 internal readonly bool _apm;
672
673 // Token: 0x040015FA RID: 5626
674 internal Stream _stream;
675
676 // Token: 0x040015FB RID: 5627
677 internal byte[] _buffer;
678
679 // Token: 0x040015FC RID: 5628
680 internal readonly int _offset;
681
682 // Token: 0x040015FD RID: 5629
683 internal readonly int _count;
684
685 // Token: 0x040015FE RID: 5630
687
688 // Token: 0x040015FF RID: 5631
690
691 // Token: 0x04001600 RID: 5632
693 }
694
695 // Token: 0x0200055A RID: 1370
696 private sealed class NullStream : Stream
697 {
698 // Token: 0x060028DF RID: 10463 RVA: 0x00058A38 File Offset: 0x00056C38
699 internal NullStream()
700 {
701 }
702
703 // Token: 0x170005E9 RID: 1513
704 // (get) Token: 0x060028E0 RID: 10464 RVA: 0x00058A4C File Offset: 0x00056C4C
705 public override bool CanRead
706 {
707 get
708 {
709 return true;
710 }
711 }
712
713 // Token: 0x170005EA RID: 1514
714 // (get) Token: 0x060028E1 RID: 10465 RVA: 0x00058A5C File Offset: 0x00056C5C
715 public override bool CanWrite
716 {
717 get
718 {
719 return true;
720 }
721 }
722
723 // Token: 0x170005EB RID: 1515
724 // (get) Token: 0x060028E2 RID: 10466 RVA: 0x00058A6C File Offset: 0x00056C6C
725 public override bool CanSeek
726 {
727 get
728 {
729 return true;
730 }
731 }
732
733 // Token: 0x170005EC RID: 1516
734 // (get) Token: 0x060028E3 RID: 10467 RVA: 0x00058A7C File Offset: 0x00056C7C
735 public override long Length
736 {
737 get
738 {
739 return 0L;
740 }
741 }
742
743 // Token: 0x170005ED RID: 1517
744 // (get) Token: 0x060028E4 RID: 10468 RVA: 0x00058A8C File Offset: 0x00056C8C
745 // (set) Token: 0x060028E5 RID: 10469 RVA: 0x00058A9C File Offset: 0x00056C9C
746 public override long Position
747 {
748 get
749 {
750 return 0L;
751 }
752 set
753 {
754 }
755 }
756
757 // Token: 0x060028E6 RID: 10470 RVA: 0x00058AAC File Offset: 0x00056CAC
758 public override void CopyTo(Stream destination, int bufferSize)
759 {
761 }
762
763 // Token: 0x060028E7 RID: 10471 RVA: 0x00058AC4 File Offset: 0x00056CC4
764 protected override void Dispose(bool disposing)
765 {
766 }
767
768 // Token: 0x060028E8 RID: 10472 RVA: 0x00058AD4 File Offset: 0x00056CD4
769 public override void Flush()
770 {
771 }
772
773 // Token: 0x060028E9 RID: 10473 RVA: 0x00058AE4 File Offset: 0x00056CE4
774 public override Task FlushAsync(CancellationToken cancellationToken)
775 {
776 if (!true)
777 {
778 }
779 Task task;
780 return task;
781 }
782
783 // Token: 0x060028EA RID: 10474 RVA: 0x00058AFC File Offset: 0x00056CFC
784 public override IAsyncResult BeginRead(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
785 {
786 return base.BlockingBeginRead(buffer, offset, count, callback, state);
787 }
788
789 // Token: 0x060028EB RID: 10475 RVA: 0x00058B20 File Offset: 0x00056D20
790 public override int EndRead(IAsyncResult asyncResult)
791 {
792 while (asyncResult == null)
793 {
794 }
795 return Stream.BlockingEndRead(asyncResult);
796 }
797
798 // Token: 0x060028EC RID: 10476 RVA: 0x00058B38 File Offset: 0x00056D38
799 public override IAsyncResult BeginWrite(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
800 {
801 return base.BlockingBeginWrite(buffer, offset, count, callback, state);
802 }
803
804 // Token: 0x060028ED RID: 10477 RVA: 0x00058B5C File Offset: 0x00056D5C
805 public override void EndWrite(IAsyncResult asyncResult)
806 {
807 while (asyncResult == null)
808 {
809 }
810 Stream.BlockingEndWrite(asyncResult);
811 }
812
813 // Token: 0x060028EE RID: 10478 RVA: 0x00058B74 File Offset: 0x00056D74
814 public override int Read(byte[] buffer, int offset, int count)
815 {
816 }
817
818 // Token: 0x060028EF RID: 10479 RVA: 0x00058B84 File Offset: 0x00056D84
819 public override int Read(Span<byte> buffer)
820 {
821 }
822
823 // Token: 0x060028F0 RID: 10480 RVA: 0x00058B94 File Offset: 0x00056D94
824 public override Task<int> ReadAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
825 {
826 if (!true)
827 {
828 }
829 return 1;
830 }
831
832 // Token: 0x060028F1 RID: 10481 RVA: 0x00058BA8 File Offset: 0x00056DA8
833 public override ValueTask<int> ReadAsync(Memory<byte> buffer, [Optional] CancellationToken cancellationToken)
834 {
835 }
836
837 // Token: 0x060028F2 RID: 10482 RVA: 0x0000207A File Offset: 0x0000027A
838 public override int ReadByte()
839 {
840 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
841 }
842
843 // Token: 0x060028F3 RID: 10483 RVA: 0x00058BB8 File Offset: 0x00056DB8
844 public override void Write(byte[] buffer, int offset, int count)
845 {
846 }
847
848 // Token: 0x060028F4 RID: 10484 RVA: 0x00058BC8 File Offset: 0x00056DC8
849 public override void Write(ReadOnlySpan<byte> buffer)
850 {
851 }
852
853 // Token: 0x060028F5 RID: 10485 RVA: 0x00058BD8 File Offset: 0x00056DD8
854 public override Task WriteAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
855 {
856 if (!true)
857 {
858 }
859 Task task;
860 return task;
861 }
862
863 // Token: 0x060028F6 RID: 10486 RVA: 0x00058BF0 File Offset: 0x00056DF0
864 public override ValueTask WriteAsync(ReadOnlyMemory<byte> buffer, [Optional] CancellationToken cancellationToken)
865 {
866 /*
867An exception occurred when decompiling this method (060028F6)
868
869ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Threading.Tasks.ValueTask System.IO.Stream/NullStream::WriteAsync(System.ReadOnlyMemory`1<System.Byte>,System.Threading.CancellationToken)
870
871 ---> System.Exception: Basic block has to end with unconditional control flow.
872{
873 Block_0:
874 call:void(ThrowHelper::ThrowArgumentNullException, ldc.i4:ExceptionArgument(38))
875}
876
877 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
878 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
879 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
880 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
881 --- End of inner exception stack trace ---
882 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
883 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
884*/;
885 }
886
887 // Token: 0x060028F7 RID: 10487 RVA: 0x00058C08 File Offset: 0x00056E08
888 public override void WriteByte(byte value)
889 {
890 }
891
892 // Token: 0x060028F8 RID: 10488 RVA: 0x00058C18 File Offset: 0x00056E18
893 public override long Seek(long offset, SeekOrigin origin)
894 {
895 return 0L;
896 }
897
898 // Token: 0x060028F9 RID: 10489 RVA: 0x00058C28 File Offset: 0x00056E28
899 public override void SetLength(long length)
900 {
901 }
902
903 // Token: 0x060028FA RID: 10490 RVA: 0x00058C38 File Offset: 0x00056E38
904 // Note: this type is marked as 'beforefieldinit'.
905 static NullStream()
906 {
907 if (!true)
908 {
909 }
910 }
911
912 // Token: 0x04001601 RID: 5633
914 }
915
916 // Token: 0x0200055B RID: 1371
918 {
919 // Token: 0x060028FB RID: 10491 RVA: 0x00058C48 File Offset: 0x00056E48
925
926 // Token: 0x060028FC RID: 10492 RVA: 0x00058C6C File Offset: 0x00056E6C
932
933 // Token: 0x060028FD RID: 10493 RVA: 0x00058C90 File Offset: 0x00056E90
940
941 // Token: 0x170005EE RID: 1518
942 // (get) Token: 0x060028FE RID: 10494 RVA: 0x00058CB8 File Offset: 0x00056EB8
943 public bool IsCompleted
944 {
945 get
946 {
947 return true;
948 }
949 }
950
951 // Token: 0x170005EF RID: 1519
952 // (get) Token: 0x060028FF RID: 10495 RVA: 0x00058CC8 File Offset: 0x00056EC8
954 {
955 get
956 {
957 /*
958An exception occurred when decompiling this method (060028FF)
959
960ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Threading.WaitHandle System.IO.Stream/SynchronousAsyncResult::get_AsyncWaitHandle()
961
962 ---> System.Exception: Basic block has to end with unconditional control flow.
963{
964 IL_0005:
965 brtrue(IL_0000, ldloc:int32[exp:bool](var_0_01))
966}
967
968 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
969 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
970 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
971 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1846
972 at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
973 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
974 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
975 --- End of inner exception stack trace ---
976 at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
977 at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1683
978*/;
979 }
980 }
981
982 // Token: 0x170005F0 RID: 1520
983 // (get) Token: 0x06002900 RID: 10496 RVA: 0x00058CDC File Offset: 0x00056EDC
984 public object AsyncState
985 {
986 get
987 {
988 return this._stateObject;
989 }
990 }
991
992 // Token: 0x170005F1 RID: 1521
993 // (get) Token: 0x06002901 RID: 10497 RVA: 0x00058CF0 File Offset: 0x00056EF0
995 {
996 get
997 {
998 return true;
999 }
1000 }
1001
1002 // Token: 0x06002902 RID: 10498 RVA: 0x00058D00 File Offset: 0x00056F00
1003 internal void ThrowIfError()
1004 {
1006 if (exceptionInfo != null)
1007 {
1009 return;
1010 }
1011 }
1012
1013 // Token: 0x06002903 RID: 10499 RVA: 0x00058D20 File Offset: 0x00056F20
1014 internal static int EndRead(IAsyncResult asyncResult)
1015 {
1016 return "IAsyncResult object did not come from the corresponding async method on this type.";
1017 }
1018
1019 // Token: 0x06002904 RID: 10500 RVA: 0x00058D34 File Offset: 0x00056F34
1020 internal static void EndWrite(IAsyncResult asyncResult)
1021 {
1022 if (asyncResult != null)
1023 {
1024 return;
1025 }
1026 }
1027
1028 // Token: 0x04001602 RID: 5634
1029 private readonly object _stateObject;
1030
1031 // Token: 0x04001603 RID: 5635
1032 private readonly bool _isWrite;
1033
1034 // Token: 0x04001604 RID: 5636
1036
1037 // Token: 0x04001605 RID: 5637
1039
1040 // Token: 0x04001606 RID: 5638
1041 private bool _endXxxCalled;
1042
1043 // Token: 0x04001607 RID: 5639
1044 private int _bytesRead;
1045
1046 // Token: 0x0200055C RID: 1372
1048 [Serializable]
1049 private sealed class <>c
1050 {
1051 // Token: 0x06002905 RID: 10501 RVA: 0x0001B05E File Offset: 0x0001925E
1052 // Note: this type is marked as 'beforefieldinit'.
1053 static <>c()
1054 {
1055 }
1056
1057 // Token: 0x06002906 RID: 10502 RVA: 0x0001B05E File Offset: 0x0001925E
1058 public <>c()
1059 {
1060 }
1061
1062 // Token: 0x06002907 RID: 10503 RVA: 0x000273E5 File Offset: 0x000255E5
1064 {
1065 return null;
1066 }
1067
1068 // Token: 0x04001608 RID: 5640
1069 public static readonly Stream.SynchronousAsyncResult.<>c <>9;
1070
1071 // Token: 0x04001609 RID: 5641
1072 public static Func<ManualResetEvent> <>9__12_0;
1073 }
1074 }
1075
1076 // Token: 0x0200055D RID: 1373
1078 [Serializable]
1079 private sealed class <>c
1080 {
1081 // Token: 0x06002908 RID: 10504 RVA: 0x00058D48 File Offset: 0x00056F48
1082 // Note: this type is marked as 'beforefieldinit'.
1083 static <>c()
1084 {
1085 }
1086
1087 // Token: 0x06002909 RID: 10505 RVA: 0x00058D58 File Offset: 0x00056F58
1088 public <>c()
1089 {
1090 }
1091
1092 // Token: 0x0600290A RID: 10506 RVA: 0x0000207A File Offset: 0x0000027A
1094 {
1095 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
1096 }
1097
1098 // Token: 0x0600290B RID: 10507 RVA: 0x00058D6C File Offset: 0x00056F6C
1099 internal void <FlushAsync>b__37_0(object state)
1100 {
1101 }
1102
1103 // Token: 0x0600290C RID: 10508 RVA: 0x00058D80 File Offset: 0x00056F80
1105 {
1106 if (!true)
1107 {
1108 }
1109 if (!true)
1110 {
1111 }
1112 if (!false)
1113 {
1114 }
1115 throw new OutOfMemoryException();
1116 }
1117
1118 // Token: 0x0600290D RID: 10509 RVA: 0x0000207A File Offset: 0x0000027A
1119 internal IAsyncResult <BeginEndReadAsync>b__45_0(Stream stream, Stream.ReadWriteParameters args, AsyncCallback callback, object state)
1120 {
1121 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
1122 }
1123
1124 // Token: 0x0600290E RID: 10510 RVA: 0x0000207A File Offset: 0x0000027A
1125 internal int <BeginEndReadAsync>b__45_1(Stream stream, IAsyncResult asyncResult)
1126 {
1127 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
1128 }
1129
1130 // Token: 0x0600290F RID: 10511 RVA: 0x00058DB0 File Offset: 0x00056FB0
1131 internal int <BeginWriteInternal>b__48_0(object <p0>)
1132 {
1133 if (!true)
1134 {
1135 }
1136 if (!true)
1137 {
1138 }
1139 if (!false)
1140 {
1141 }
1142 throw new OutOfMemoryException();
1143 }
1144
1145 // Token: 0x06002910 RID: 10512 RVA: 0x00058DE4 File Offset: 0x00056FE4
1147 {
1148 if (state != null)
1149 {
1150 }
1151 }
1152
1153 // Token: 0x06002911 RID: 10513 RVA: 0x0000207A File Offset: 0x0000027A
1154 internal IAsyncResult <BeginEndWriteAsync>b__58_0(Stream stream, Stream.ReadWriteParameters args, AsyncCallback callback, object state)
1155 {
1156 throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
1157 }
1158
1159 // Token: 0x06002912 RID: 10514 RVA: 0x00058DFC File Offset: 0x00056FFC
1161 {
1162 }
1163
1164 // Token: 0x0400160A RID: 5642
1165 public static readonly Stream.<>c <>9;
1166
1167 // Token: 0x0400160B RID: 5643
1168 public static Func<SemaphoreSlim> <>9__4_0;
1169
1170 // Token: 0x0400160C RID: 5644
1171 public static Action<object> <>9__37_0;
1172
1173 // Token: 0x0400160D RID: 5645
1174 public static Func<object, int> <>9__40_0;
1175
1176 // Token: 0x0400160E RID: 5646
1177 public static Func<Stream, Stream.ReadWriteParameters, AsyncCallback, object, IAsyncResult> <>9__45_0;
1178
1179 // Token: 0x0400160F RID: 5647
1180 public static Func<Stream, IAsyncResult, int> <>9__45_1;
1181
1182 // Token: 0x04001610 RID: 5648
1183 public static Func<object, int> <>9__48_0;
1184
1185 // Token: 0x04001611 RID: 5649
1186 public static Action<Task, object> <>9__49_0;
1187
1188 // Token: 0x04001612 RID: 5650
1189 public static Func<Stream, Stream.ReadWriteParameters, AsyncCallback, object, IAsyncResult> <>9__58_0;
1190
1191 // Token: 0x04001613 RID: 5651
1193 }
1194
1195 // Token: 0x0200055E RID: 1374
1197 [StructLayout(3)]
1199 {
1200 // Token: 0x06002913 RID: 10515 RVA: 0x00058E0C File Offset: 0x0005700C
1201 private void MoveNext()
1202 {
1203 Task task = this.writeTask;
1204 long num = 0L;
1205 ConfiguredTaskAwaitable configuredTaskAwaitable = task.ConfigureAwait(num != 0L);
1206 }
1207
1208 // Token: 0x06002914 RID: 10516 RVA: 0x00058E40 File Offset: 0x00057040
1213
1214 // Token: 0x04001614 RID: 5652
1216
1217 // Token: 0x04001615 RID: 5653
1219
1220 // Token: 0x04001616 RID: 5654
1222
1223 // Token: 0x04001617 RID: 5655
1224 public byte[] localBuffer;
1225
1226 // Token: 0x04001618 RID: 5656
1228 }
1229
1230 // Token: 0x0200055F RID: 1375
1232 [StructLayout(3)]
1234 {
1235 // Token: 0x06002915 RID: 10517 RVA: 0x00058E50 File Offset: 0x00057050
1236 private void MoveNext()
1237 {
1238 Task<int> task = this.readTask;
1239 }
1240
1241 // Token: 0x06002916 RID: 10518 RVA: 0x00058E98 File Offset: 0x00057098
1246
1247 // Token: 0x04001619 RID: 5657
1249
1250 // Token: 0x0400161A RID: 5658
1252
1253 // Token: 0x0400161B RID: 5659
1255
1256 // Token: 0x0400161C RID: 5660
1257 public byte[] localBuffer;
1258
1259 // Token: 0x0400161D RID: 5661
1261
1262 // Token: 0x0400161E RID: 5662
1264 }
1265 }
1266}
class f__AnonymousType0<< Count > j__TPar
IntPtr method_code
Definition Delegate.cs:386
IntPtr invoke_impl
Definition Delegate.cs:371
static void SuppressFinalize(object obj)
Definition GC.cs:116
static void ValidateCopyToArgs(Stream source, Stream destination, int bufferSize)
override IAsyncResult BeginRead(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
Definition Stream.cs:784
override void Write(ReadOnlySpan< byte > buffer)
Definition Stream.cs:849
override void Flush()
Definition Stream.cs:769
override Task FlushAsync(CancellationToken cancellationToken)
Definition Stream.cs:774
override long Seek(long offset, SeekOrigin origin)
Definition Stream.cs:893
override void Dispose(bool disposing)
Definition Stream.cs:764
override IAsyncResult BeginWrite(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
Definition Stream.cs:799
override int Read(Span< byte > buffer)
Definition Stream.cs:819
override ValueTask WriteAsync(ReadOnlyMemory< byte > buffer, [Optional] CancellationToken cancellationToken)
Definition Stream.cs:864
override void CopyTo(Stream destination, int bufferSize)
Definition Stream.cs:758
override void EndWrite(IAsyncResult asyncResult)
Definition Stream.cs:805
override void WriteByte(byte value)
Definition Stream.cs:888
override Task WriteAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
Definition Stream.cs:854
override bool CanRead
Definition Stream.cs:706
override void SetLength(long length)
Definition Stream.cs:899
override int ReadByte()
Definition Stream.cs:838
static readonly Task< int > s_zeroTask
Definition Stream.cs:913
override ValueTask< int > ReadAsync(Memory< byte > buffer, [Optional] CancellationToken cancellationToken)
Definition Stream.cs:833
override void Write(byte[] buffer, int offset, int count)
Definition Stream.cs:844
override bool CanWrite
Definition Stream.cs:716
override int EndRead(IAsyncResult asyncResult)
Definition Stream.cs:790
override bool CanSeek
Definition Stream.cs:726
override int Read(byte[] buffer, int offset, int count)
Definition Stream.cs:814
override Task< int > ReadAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
Definition Stream.cs:824
override long Position
Definition Stream.cs:747
static void InvokeAsyncCallback(object completedTask)
Definition Stream.cs:637
ReadWriteTask(bool isRead, bool apm, Func< object, int > function, object state, Stream stream, byte[] buffer, int offset, int count, AsyncCallback callback)
Definition Stream.cs:622
ExecutionContext _context
Definition Stream.cs:689
static ContextCallback s_invokeAsyncCallback
Definition Stream.cs:692
SynchronousAsyncResult(object asyncStateObject)
Definition Stream.cs:927
SynchronousAsyncResult(int bytesRead, object asyncStateObject)
Definition Stream.cs:920
static void EndWrite(IAsyncResult asyncResult)
Definition Stream.cs:1020
static int EndRead(IAsyncResult asyncResult)
Definition Stream.cs:1014
SynchronousAsyncResult(Exception ex, object asyncStateObject, bool isWrite)
Definition Stream.cs:934
ExceptionDispatchInfo _exceptionInfo
Definition Stream.cs:1038
IAsyncResult BeginReadInternal(byte[] buffer, int offset, int count, AsyncCallback callback, object state, bool serializeAsynchronously, bool apm)
Definition Stream.cs:158
virtual void Dispose(bool disposing)
Definition Stream.cs:130
static ValueTask< int >< ReadAsync > g__FinishReadAsync(Task< int > readTask, byte[] localBuffer, Memory< byte > localDestination)
Definition Stream.cs:582
virtual int ReadByte()
Definition Stream.cs:471
virtual ValueTask< int > ReadAsync(Memory< byte > buffer, [Optional] CancellationToken cancellationToken)
Definition Stream.cs:232
bool HasOverriddenBeginEndRead()
Definition Stream.cs:558
IAsyncResult BlockingBeginWrite(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
Definition Stream.cs:538
Task BeginEndWriteAsync(byte[] buffer, int offset, int count)
Definition Stream.cs:408
void SetLength(long value)
bool HasOverriddenBeginEndWrite()
Definition Stream.cs:564
virtual void Write(ReadOnlySpan< byte > buffer)
Definition Stream.cs:501
long Seek(long offset, SeekOrigin origin)
virtual bool CanTimeout
Definition Stream.cs:41
virtual Task FlushAsync(CancellationToken cancellationToken)
Definition Stream.cs:138
void RunReadWriteTask(Stream.ReadWriteTask readWriteTask)
Definition Stream.cs:300
IAsyncResult BeginWriteInternal(byte[] buffer, int offset, int count, AsyncCallback callback, object state, bool serializeAsynchronously, bool apm)
Definition Stream.cs:269
Task FinishWriteAsync(Task writeTask, byte[] localBuffer)
Definition Stream.cs:397
virtual void Close()
Definition Stream.cs:119
virtual int ReadTimeout
Definition Stream.cs:64
Task WriteAsync(byte[] buffer, int offset, int count)
Definition Stream.cs:342
virtual void EndWrite(IAsyncResult asyncResult)
Definition Stream.cs:321
virtual ValueTask WriteAsync(ReadOnlyMemory< byte > buffer, [Optional] CancellationToken cancellationToken)
Definition Stream.cs:373
int Read(byte[] buffer, int offset, int count)
virtual int Read(Span< byte > buffer)
Definition Stream.cs:447
void FinishTrackingAsyncOperation()
Definition Stream.cs:315
IAsyncResult BlockingBeginRead(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
Definition Stream.cs:517
virtual void CopyTo(Stream destination, int bufferSize)
Definition Stream.cs:97
void CopyTo(Stream destination)
Definition Stream.cs:91
void Dispose()
Definition Stream.cs:125
virtual Task< int > ReadAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
Definition Stream.cs:225
static Stream()
Definition Stream.cs:576
int GetCopyBufferSize()
Definition Stream.cs:113
Task< int > ReadAsync(byte[] buffer, int offset, int count)
Definition Stream.cs:201
SemaphoreSlim _asyncActiveSemaphore
Definition Stream.cs:598
static void BlockingEndWrite(IAsyncResult asyncResult)
Definition Stream.cs:552
void Write(byte[] buffer, int offset, int count)
virtual IAsyncResult BeginWrite(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
Definition Stream.cs:262
virtual void WriteByte(byte value)
Definition Stream.cs:512
void RunReadWriteTaskWhenReady(Task asyncWaiter, Stream.ReadWriteTask readWriteTask)
Definition Stream.cs:293
virtual IAsyncResult BeginRead(byte[] buffer, int offset, int count, AsyncCallback callback, object state)
Definition Stream.cs:151
virtual int WriteTimeout
Definition Stream.cs:79
Task< int > BeginEndReadAsync(byte[] buffer, int offset, int count)
Definition Stream.cs:243
virtual int EndRead(IAsyncResult asyncResult)
Definition Stream.cs:182
static readonly Stream Null
Definition Stream.cs:590
SemaphoreSlim EnsureAsyncActiveSemaphoreInitialized()
Definition Stream.cs:17
Stream.ReadWriteTask _activeReadWriteTask
Definition Stream.cs:594
virtual Task WriteAsync(byte[] buffer, int offset, int count, CancellationToken cancellationToken)
Definition Stream.cs:366
static int BlockingEndRead(IAsyncResult asyncResult)
Definition Stream.cs:531
static ExceptionDispatchInfo Capture(Exception source)
static ExecutionContext Capture()
static void ThrowArgumentNullException(ExceptionArgument argument)
void SetStateMachine(IAsyncStateMachine stateMachine)
Definition Stream.cs:1210
ConfiguredTaskAwaitable.ConfiguredTaskAwaiter u__1
Definition Stream.cs:1227
AsyncTaskMethodBuilder t__builder
Definition Stream.cs:1218
AsyncValueTaskMethodBuilder< int ><> t__builder
Definition Stream.cs:1251
ConfiguredTaskAwaitable< int >.ConfiguredTaskAwaiter u__1
Definition Stream.cs:1263
Task< int > readTask
Definition Stream.cs:1254
void SetStateMachine(IAsyncStateMachine stateMachine)
Definition Stream.cs:1243
Memory< byte > localDestination
Definition Stream.cs:1260