Files
Jan2021-Cpp2Il-Dump/Assembly-CSharp/Steamworks/CallResult.2.cs
T
2026-04-08 23:40:05 +02:00

258 lines
9.9 KiB
C#

using System;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using Cpp2IlInjected;
namespace Steamworks
{
// Token: 0x0200108E RID: 4238
[Token(Token = "0x200108E")]
[StructLayout(3)]
public sealed class CallResult<T> : CallResult, IDisposable
{
// Token: 0x140000A3 RID: 163
// (add) Token: 0x0600675D RID: 26461 RVA: 0x0016A748 File Offset: 0x00168948
// (remove) Token: 0x0600675E RID: 26462 RVA: 0x0016A770 File Offset: 0x00168970
[Token(Token = "0x140000A3")]
private event CallResult<T>.APIDispatchDelegate m_Func
{
[Token(Token = "0x600675D")]
[Address(RVA = "0x2314DA0", Offset = "0x23137A0", VA = "0x182314DA0")]
[CompilerGenerated]
add
{
CallResult.APIDispatchDelegate func;
Delegate @delegate;
do
{
func = this.m_Func;
@delegate = Delegate.Combine(func, value);
if (@delegate == 0)
{
}
}
while (@delegate == 0);
while (@delegate != func)
{
}
}
[Token(Token = "0x600675E")]
[Address(RVA = "0x2314E60", Offset = "0x2313860", VA = "0x182314E60")]
[CompilerGenerated]
remove
{
CallResult.APIDispatchDelegate func;
Delegate @delegate;
do
{
func = this.m_Func;
@delegate = Delegate.Remove(func, value);
if (@delegate == 0)
{
}
}
while (@delegate == 0);
while (@delegate != func)
{
}
}
}
// Token: 0x17001286 RID: 4742
// (get) Token: 0x0600675F RID: 26463 RVA: 0x0016A798 File Offset: 0x00168998
[Token(Token = "0x17001286")]
public SteamAPICall_t Handle
{
[Token(Token = "0x600675F")]
[Address(RVA = "0x3C1240", Offset = "0x3BFC40", VA = "0x1803C1240")]
get
{
return this.m_hAPICall;
}
}
// Token: 0x06006760 RID: 26464 RVA: 0x0016A7AC File Offset: 0x001689AC
[Token(Token = "0x6006760")]
[Address(RVA = "0x23146A0", Offset = "0x23130A0", VA = "0x1823146A0")]
public static CallResult<T> Create([Optional] CallResult<T>.APIDispatchDelegate func)
{
return new CallResult(func);
}
// Token: 0x06006761 RID: 26465 RVA: 0x0016A7C0 File Offset: 0x001689C0
[Token(Token = "0x6006761")]
[Address(RVA = "0x2314D20", Offset = "0x2313720", VA = "0x182314D20")]
public CallResult([Optional] CallResult<T>.APIDispatchDelegate func)
{
SteamAPICall_t invalid = SteamAPICall_t.Invalid;
this.m_hAPICall = invalid;
base..ctor();
this.m_Func = func;
}
// Token: 0x06006762 RID: 26466 RVA: 0x0016A7E8 File Offset: 0x001689E8
[Token(Token = "0x6006762")]
[Address(RVA = "0x23147F0", Offset = "0x23131F0", VA = "0x1823147F0", Slot = "1")]
protected override void Finalize()
{
int num;
do
{
num = 0;
this.Dispose();
base..ctor();
if (num != -1)
{
}
}
while (num != 0);
}
// Token: 0x06006763 RID: 26467 RVA: 0x0016A814 File Offset: 0x00168A14
[Token(Token = "0x6006763")]
[Address(RVA = "0x2314770", Offset = "0x2313170", VA = "0x182314770", Slot = "7")]
public void Dispose()
{
GC.SuppressFinalize(this);
this.Cancel();
this.m_bDisposed = true;
}
// Token: 0x06006764 RID: 26468 RVA: 0x0016A834 File Offset: 0x00168A34
[Token(Token = "0x6006764")]
[Address(RVA = "0x2314BA0", Offset = "0x23135A0", VA = "0x182314BA0")]
public void Set(SteamAPICall_t hAPICall, [Optional] CallResult<T>.APIDispatchDelegate func)
{
/*
An exception occurred when decompiling this method (06006764)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void Steamworks.CallResult`1::Set(Steamworks.SteamAPICall_t,Steamworks.CallResult`1/APIDispatchDelegate<T>)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_56:
stloc:Exception(var_3_60, newobj:Exception(Exception::.ctor, ldstr:string("CallResult function was null, you must either set it in the CallResult Constructor or via Set()")))
}
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
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
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
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
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
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
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
--- End of inner exception stack trace ---
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
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 1663
*/;
}
// Token: 0x06006765 RID: 26469 RVA: 0x0016A8A4 File Offset: 0x00168AA4
[Token(Token = "0x6006765")]
[Address(RVA = "0x2314910", Offset = "0x2313310", VA = "0x182314910")]
public bool IsActive()
{
SteamAPICall_t hAPICall = this.m_hAPICall;
SteamAPICall_t invalid = SteamAPICall_t.Invalid;
return hAPICall != invalid;
}
// Token: 0x06006766 RID: 26470 RVA: 0x0016A8C8 File Offset: 0x00168AC8
[Token(Token = "0x6006766")]
[Address(RVA = "0x2314610", Offset = "0x2313010", VA = "0x182314610")]
public void Cancel()
{
if (this.IsActive())
{
CallbackDispatcher.Unregister(this.m_hAPICall, this);
}
}
// Token: 0x06006767 RID: 26471 RVA: 0x0016A8F0 File Offset: 0x00168AF0
[Token(Token = "0x6006767")]
[Address(RVA = "0x23148B0", Offset = "0x23132B0", VA = "0x1823148B0", Slot = "4")]
internal override Type GetCallbackType()
{
Type type;
return type;
}
// Token: 0x06006768 RID: 26472 RVA: 0x0016A900 File Offset: 0x00168B00
[Token(Token = "0x6006768")]
[Address(RVA = "0x2314980", Offset = "0x2313380", VA = "0x182314980", Slot = "5")]
internal override void OnRunCallResult(IntPtr pvParam, bool bFailed, ulong hSteamAPICall_)
{
CallResult.APIDispatchDelegate func = this.m_Func;
Type type;
object obj = Marshal.PtrToStructure(pvParam, type);
if (obj == 0)
{
}
if (obj != 0)
{
return;
}
throw new NullReferenceException();
}
// Token: 0x06006769 RID: 26473 RVA: 0x0016A92C File Offset: 0x00168B2C
[Token(Token = "0x6006769")]
[Address(RVA = "0x2314B40", Offset = "0x2313540", VA = "0x182314B40", Slot = "6")]
internal override void SetUnregistered()
{
SteamAPICall_t invalid = SteamAPICall_t.Invalid;
this.m_hAPICall = invalid;
}
// Token: 0x04004975 RID: 18805
[global::Cpp2IlInjected.FieldOffset(Offset = "0x0")]
[Token(Token = "0x4004975")]
private SteamAPICall_t m_hAPICall;
// Token: 0x04004976 RID: 18806
[global::Cpp2IlInjected.FieldOffset(Offset = "0x0")]
[Token(Token = "0x4004976")]
private bool m_bDisposed;
// Token: 0x0200108F RID: 4239
[Token(Token = "0x200108F")]
public sealed class APIDispatchDelegate : MulticastDelegate
{
// Token: 0x0600676A RID: 26474 RVA: 0x0016A948 File Offset: 0x00168B48
[Token(Token = "0x600676A")]
[Address(RVA = "0x3E5170", Offset = "0x3E3B70", VA = "0x1803E5170")]
public APIDispatchDelegate(object @object, IntPtr method)
{
}
// Token: 0x0600676B RID: 26475 RVA: 0x0016A958 File Offset: 0x00168B58
[Token(Token = "0x600676B")]
[Address(RVA = "0xC3BD70", Offset = "0xC3A770", VA = "0x180C3BD70", Slot = "13")]
public void Invoke(T param, bool bIOFailure)
{
uint num;
if (num != (uint)0)
{
throw new ExecutionEngineException();
}
}
// Token: 0x0600676C RID: 26476 RVA: 0x0000220F File Offset: 0x0000040F
[Token(Token = "0x600676C")]
[Address(RVA = "0x2310DE0", Offset = "0x230F7E0", VA = "0x182310DE0", Slot = "14")]
public IAsyncResult BeginInvoke(T param, bool bIOFailure, AsyncCallback callback, object @object)
{
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
}
// Token: 0x0600676D RID: 26477 RVA: 0x0000220F File Offset: 0x0000040F
[Token(Token = "0x600676D")]
[Address(RVA = "0x40BFF0", Offset = "0x40A9F0", VA = "0x18040BFF0", Slot = "15")]
public void EndInvoke(IAsyncResult result)
{
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
}
}
}
}