using System; using System.Collections.Generic; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using BestHTTP.Extensions; using BestHTTP.Futures; using BestHTTP.Logger; using BestHTTP.SignalRCore.Authentication; using BestHTTP.SignalRCore.Messages; using Cpp2IlInjected; namespace BestHTTP.SignalRCore { // Token: 0x020018DF RID: 6367 [Token(Token = "0x20018DF")] public sealed class HubConnection : IHeartbeat { // Token: 0x170017D8 RID: 6104 // (get) Token: 0x060095B0 RID: 38320 RVA: 0x001EC77C File Offset: 0x001EA97C // (set) Token: 0x060095B1 RID: 38321 RVA: 0x001EC790 File Offset: 0x001EA990 [Token(Token = "0x170017D8")] public Uri Uri { [Token(Token = "0x60095B0")] [Address(RVA = "0x3F6E20", Offset = "0x3F5C20", VA = "0x1803F6E20")] get; [Token(Token = "0x60095B1")] [Address(RVA = "0x3F7200", Offset = "0x3F6000", VA = "0x1803F7200")] private set; } // Token: 0x170017D9 RID: 6105 // (get) Token: 0x060095B2 RID: 38322 RVA: 0x001EC7A4 File Offset: 0x001EA9A4 // (set) Token: 0x060095B3 RID: 38323 RVA: 0x001EC7B8 File Offset: 0x001EA9B8 [Token(Token = "0x170017D9")] public ConnectionStates State { [Token(Token = "0x60095B2")] [Address(RVA = "0x40B720", Offset = "0x40A520", VA = "0x18040B720")] get; [Token(Token = "0x60095B3")] [Address(RVA = "0x41F740", Offset = "0x41E540", VA = "0x18041F740")] private set; } // Token: 0x170017DA RID: 6106 // (get) Token: 0x060095B4 RID: 38324 RVA: 0x001EC7CC File Offset: 0x001EA9CC // (set) Token: 0x060095B5 RID: 38325 RVA: 0x001EC7E0 File Offset: 0x001EA9E0 [Token(Token = "0x170017DA")] public ITransport Transport { [Token(Token = "0x60095B4")] [Address(RVA = "0x3F6400", Offset = "0x3F5200", VA = "0x1803F6400")] get; [Token(Token = "0x60095B5")] [Address(RVA = "0x460F90", Offset = "0x45FD90", VA = "0x180460F90")] private set; } // Token: 0x170017DB RID: 6107 // (get) Token: 0x060095B6 RID: 38326 RVA: 0x001EC7F4 File Offset: 0x001EA9F4 // (set) Token: 0x060095B7 RID: 38327 RVA: 0x001EC808 File Offset: 0x001EAA08 [Token(Token = "0x170017DB")] public IProtocol Protocol { [Token(Token = "0x60095B6")] [Address(RVA = "0x3F63E0", Offset = "0x3F51E0", VA = "0x1803F63E0")] get; [Token(Token = "0x60095B7")] [Address(RVA = "0x409C60", Offset = "0x408A60", VA = "0x180409C60")] private set; } // Token: 0x140000C2 RID: 194 // (add) Token: 0x060095B8 RID: 38328 RVA: 0x001EC81C File Offset: 0x001EAA1C // (remove) Token: 0x060095B9 RID: 38329 RVA: 0x001EC844 File Offset: 0x001EAA44 [Token(Token = "0x140000C2")] public event Action OnRedirected { [Token(Token = "0x60095B8")] [Address(RVA = "0x1C37A10", Offset = "0x1C36810", VA = "0x181C37A10")] [CompilerGenerated] add { Action onRedirected; Delegate @delegate; do { onRedirected = this.OnRedirected; @delegate = Delegate.Combine(onRedirected, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onRedirected) { } } [Token(Token = "0x60095B9")] [Address(RVA = "0x1C37D30", Offset = "0x1C36B30", VA = "0x181C37D30")] [CompilerGenerated] remove { Action onRedirected; Delegate @delegate; do { onRedirected = this.OnRedirected; @delegate = Delegate.Remove(onRedirected, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onRedirected) { } } } // Token: 0x140000C3 RID: 195 // (add) Token: 0x060095BA RID: 38330 RVA: 0x001EC86C File Offset: 0x001EAA6C // (remove) Token: 0x060095BB RID: 38331 RVA: 0x001EC894 File Offset: 0x001EAA94 [Token(Token = "0x140000C3")] public event Action OnConnected { [Token(Token = "0x60095BA")] [Address(RVA = "0x1C37830", Offset = "0x1C36630", VA = "0x181C37830")] [CompilerGenerated] add { Action onConnected; Delegate @delegate; do { onConnected = this.OnConnected; @delegate = Delegate.Combine(onConnected, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onConnected) { } } [Token(Token = "0x60095BB")] [Address(RVA = "0x1C37B50", Offset = "0x1C36950", VA = "0x181C37B50")] [CompilerGenerated] remove { Action onConnected; Delegate @delegate; do { onConnected = this.OnConnected; @delegate = Delegate.Remove(onConnected, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onConnected) { } } } // Token: 0x140000C4 RID: 196 // (add) Token: 0x060095BC RID: 38332 RVA: 0x001EC8BC File Offset: 0x001EAABC // (remove) Token: 0x060095BD RID: 38333 RVA: 0x001EC8E4 File Offset: 0x001EAAE4 [Token(Token = "0x140000C4")] public event Action OnError { [Token(Token = "0x60095BC")] [Address(RVA = "0x1C378D0", Offset = "0x1C366D0", VA = "0x181C378D0")] [CompilerGenerated] add { Action onError; Delegate @delegate; do { onError = this.OnError; @delegate = Delegate.Combine(onError, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onError) { } } [Token(Token = "0x60095BD")] [Address(RVA = "0x1C37BF0", Offset = "0x1C369F0", VA = "0x181C37BF0")] [CompilerGenerated] remove { Action onError; Delegate @delegate; do { onError = this.OnError; @delegate = Delegate.Remove(onError, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onError) { } } } // Token: 0x140000C5 RID: 197 // (add) Token: 0x060095BE RID: 38334 RVA: 0x001EC90C File Offset: 0x001EAB0C // (remove) Token: 0x060095BF RID: 38335 RVA: 0x001EC934 File Offset: 0x001EAB34 [Token(Token = "0x140000C5")] public event Action OnClosed { [Token(Token = "0x60095BE")] [Address(RVA = "0x1C37790", Offset = "0x1C36590", VA = "0x181C37790")] [CompilerGenerated] add { Action onClosed; Delegate @delegate; do { onClosed = this.OnClosed; @delegate = Delegate.Combine(onClosed, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onClosed) { } } [Token(Token = "0x60095BF")] [Address(RVA = "0x1C37AB0", Offset = "0x1C368B0", VA = "0x181C37AB0")] [CompilerGenerated] remove { Action onClosed; Delegate @delegate; do { onClosed = this.OnClosed; @delegate = Delegate.Remove(onClosed, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onClosed) { } } } // Token: 0x140000C6 RID: 198 // (add) Token: 0x060095C0 RID: 38336 RVA: 0x001EC95C File Offset: 0x001EAB5C // (remove) Token: 0x060095C1 RID: 38337 RVA: 0x001EC984 File Offset: 0x001EAB84 [Token(Token = "0x140000C6")] public event Func OnMessage { [Token(Token = "0x60095C0")] [Address(RVA = "0x1C37970", Offset = "0x1C36770", VA = "0x181C37970")] [CompilerGenerated] add { Func onMessage; Delegate @delegate; do { onMessage = this.OnMessage; @delegate = Delegate.Combine(onMessage, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onMessage) { } } [Token(Token = "0x60095C1")] [Address(RVA = "0x1C37C90", Offset = "0x1C36A90", VA = "0x181C37C90")] [CompilerGenerated] remove { Func onMessage; Delegate @delegate; do { onMessage = this.OnMessage; @delegate = Delegate.Remove(onMessage, value); } while (@delegate != 0 && @delegate == 0); while (@delegate != onMessage) { } } } // Token: 0x170017DC RID: 6108 // (get) Token: 0x060095C2 RID: 38338 RVA: 0x001EC9AC File Offset: 0x001EABAC // (set) Token: 0x060095C3 RID: 38339 RVA: 0x001EC9C0 File Offset: 0x001EABC0 [Token(Token = "0x170017DC")] public IAuthenticationProvider AuthenticationProvider { [Token(Token = "0x60095C2")] [Address(RVA = "0x423D40", Offset = "0x422B40", VA = "0x180423D40")] get; [Token(Token = "0x60095C3")] [Address(RVA = "0x466B90", Offset = "0x465990", VA = "0x180466B90")] set; } // Token: 0x170017DD RID: 6109 // (get) Token: 0x060095C4 RID: 38340 RVA: 0x001EC9D4 File Offset: 0x001EABD4 // (set) Token: 0x060095C5 RID: 38341 RVA: 0x001EC9E8 File Offset: 0x001EABE8 [Token(Token = "0x170017DD")] public NegotiationResult NegotiationResult { [Token(Token = "0x60095C4")] [Address(RVA = "0x423DE0", Offset = "0x422BE0", VA = "0x180423DE0")] get; [Token(Token = "0x60095C5")] [Address(RVA = "0x567490", Offset = "0x566290", VA = "0x180567490")] private set; } // Token: 0x170017DE RID: 6110 // (get) Token: 0x060095C6 RID: 38342 RVA: 0x001EC9FC File Offset: 0x001EABFC // (set) Token: 0x060095C7 RID: 38343 RVA: 0x001ECA10 File Offset: 0x001EAC10 [Token(Token = "0x170017DE")] public HubOptions Options { [Token(Token = "0x60095C6")] [Address(RVA = "0x423E10", Offset = "0x422C10", VA = "0x180423E10")] get; [Token(Token = "0x60095C7")] [Address(RVA = "0x687270", Offset = "0x686070", VA = "0x180687270")] private set; } // Token: 0x170017DF RID: 6111 // (get) Token: 0x060095C8 RID: 38344 RVA: 0x001ECA24 File Offset: 0x001EAC24 // (set) Token: 0x060095C9 RID: 38345 RVA: 0x001ECA38 File Offset: 0x001EAC38 [Token(Token = "0x170017DF")] public int RedirectCount { [Token(Token = "0x60095C8")] [Address(RVA = "0x5672E0", Offset = "0x5660E0", VA = "0x1805672E0")] get; [Token(Token = "0x60095C9")] [Address(RVA = "0x5674F0", Offset = "0x5662F0", VA = "0x1805674F0")] private set; } // Token: 0x060095CA RID: 38346 RVA: 0x001ECA4C File Offset: 0x001EAC4C [Token(Token = "0x60095CA")] [Address(RVA = "0x1C374D0", Offset = "0x1C362D0", VA = "0x181C374D0")] public HubConnection(Uri hubUri, IProtocol protocol) { HubOptions hubOptions = new HubOptions(); hubOptions.k__BackingField = false; hubOptions.k__BackingField = (TransportTypes)((ulong)0L); TimeSpan timeSpan; hubOptions.k__BackingField = timeSpan; hubOptions.k__BackingField = (int)((ulong)100L); } // Token: 0x060095CB RID: 38347 RVA: 0x001ECA80 File Offset: 0x001EAC80 [Token(Token = "0x60095CB")] [Address(RVA = "0x1C375B0", Offset = "0x1C363B0", VA = "0x181C375B0")] public HubConnection(Uri hubUri, IProtocol protocol, HubOptions options) { Dictionary> dictionary = new Dictionary(); this.invocations = dictionary; Dictionary dictionary2 = new Dictionary(StringComparer._ordinalIgnoreCase); this.subscriptions = dictionary2; base..ctor(); int num = 0; this.Uri = hubUri; this.State = (ConnectionStates)num; this.Options = options; this.Protocol = protocol; num += num; num++; DefaultAccessTokenAuthenticator defaultAccessTokenAuthenticator; defaultAccessTokenAuthenticator.StartAuthentication(); defaultAccessTokenAuthenticator._connection = this; this.AuthenticationProvider = defaultAccessTokenAuthenticator; } // Token: 0x060095CC RID: 38348 RVA: 0x001ECAFC File Offset: 0x001EACFC [Token(Token = "0x60095CC")] [Address(RVA = "0x1C36D50", Offset = "0x1C35B50", VA = "0x181C36D50")] public void StartConnect() { ConnectionStates connectionStates = this.k__BackingField; if (connectionStates != ConnectionStates.Initial && connectionStates != ConnectionStates.Redirected) { ILogger logger = HTTPManager.Logger; ConnectionStates connectionStates2 = this.k__BackingField; return; } ILogger logger2 = HTTPManager.Logger; if (this.k__BackingField != 0 && logger2 != 0) { ILogger logger3 = HTTPManager.Logger; int num = 0; this.SetState(ConnectionStates.Authenticating, num); IAuthenticationProvider authenticationProvider = this.k__BackingField; OnAuthenticationSuccededDelegate onAuthenticationSuccededDelegate; onAuthenticationSuccededDelegate.method_ptr = ldftn(OnAuthenticationSucceded); onAuthenticationSuccededDelegate.method = ldftn(OnAuthenticationSucceded); onAuthenticationSuccededDelegate.m_target = this; IAuthenticationProvider authenticationProvider2 = this.k__BackingField; OnAuthenticationFailedDelegate onAuthenticationFailedDelegate; onAuthenticationFailedDelegate.method_ptr = ldftn(OnAuthenticationFailed); onAuthenticationFailedDelegate.method = ldftn(OnAuthenticationFailed); onAuthenticationFailedDelegate.m_target = this; IAuthenticationProvider authenticationProvider3 = this.k__BackingField; return; } this.StartNegotiation(); } // Token: 0x060095CD RID: 38349 RVA: 0x001ECBC4 File Offset: 0x001EADC4 [Token(Token = "0x60095CD")] [Address(RVA = "0x1C35190", Offset = "0x1C33F90", VA = "0x181C35190")] private void OnAuthenticationSucceded(IAuthenticationProvider provider) { ILogger logger = HTTPManager.Logger; IAuthenticationProvider authenticationProvider = this.k__BackingField; OnAuthenticationSuccededDelegate onAuthenticationSuccededDelegate; onAuthenticationSuccededDelegate.method_ptr = ldftn(OnAuthenticationSucceded); onAuthenticationSuccededDelegate.method = ldftn(OnAuthenticationSucceded); onAuthenticationSuccededDelegate.m_target = this; IAuthenticationProvider authenticationProvider2 = this.k__BackingField; OnAuthenticationFailedDelegate onAuthenticationFailedDelegate; onAuthenticationFailedDelegate.method_ptr = ldftn(OnAuthenticationFailed); onAuthenticationFailedDelegate.method = ldftn(OnAuthenticationFailed); onAuthenticationFailedDelegate.m_target = this; this.StartNegotiation(); } // Token: 0x060095CE RID: 38350 RVA: 0x001ECC38 File Offset: 0x001EAE38 [Token(Token = "0x60095CE")] [Address(RVA = "0x1C35050", Offset = "0x1C33E50", VA = "0x181C35050")] private void OnAuthenticationFailed(IAuthenticationProvider provider, string reason) { ILogger logger = HTTPManager.Logger; string text = "OnAuthenticationFailed: " + reason; IAuthenticationProvider authenticationProvider = this.k__BackingField; OnAuthenticationSuccededDelegate onAuthenticationSuccededDelegate; onAuthenticationSuccededDelegate.method_ptr = ldftn(OnAuthenticationSucceded); onAuthenticationSuccededDelegate.method = ldftn(OnAuthenticationSucceded); onAuthenticationSuccededDelegate.m_target = this; IAuthenticationProvider authenticationProvider2 = this.k__BackingField; OnAuthenticationFailedDelegate onAuthenticationFailedDelegate; onAuthenticationFailedDelegate.method_ptr = ldftn(OnAuthenticationFailed); onAuthenticationFailedDelegate.method = ldftn(OnAuthenticationFailed); onAuthenticationFailedDelegate.m_target = this; this.SetState(ConnectionStates.Closed, reason); } // Token: 0x060095CF RID: 38351 RVA: 0x001ECCBC File Offset: 0x001EAEBC [Token(Token = "0x60095CF")] [Address(RVA = "0x1C37010", Offset = "0x1C35E10", VA = "0x181C37010")] private void StartNegotiation() { ILogger logger = HTTPManager.Logger; if (this.k__BackingField != ConnectionStates.CloseInitiated) { if (!this.k__BackingField.k__BackingField) { int num = 0; this.SetState(ConnectionStates.Negotiating, num); UriBuilder uriBuilder = new UriBuilder(this.k__BackingField); if (!uriBuilder._path.EndsWith("/")) { string text = uriBuilder._path + "/"; uriBuilder.Path = text; } string text2 = uriBuilder._path + "negotiate"; uriBuilder.Path = text2; Uri uri = uriBuilder.Uri; Action action = new Action(this.OnNegotiationRequestFinished); int num2 = 0; if (this.k__BackingField != 0 && num2 < uri) { num2 += num2; num2++; } NEBIGEDJGPP nebigedjgpp; nebigedjgpp.GDOIHJPIPBM(); return; } ILogger logger2 = HTTPManager.Logger; this.ConnectImpl(); } int num3 = 0; this.SetState(ConnectionStates.Closed, num3); throw new NullReferenceException(); } // Token: 0x060095D0 RID: 38352 RVA: 0x0000220F File Offset: 0x0000040F [Token(Token = "0x60095D0")] [Address(RVA = "0x1C34AB0", Offset = "0x1C338B0", VA = "0x181C34AB0")] private void ConnectImpl() { throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method."); } // Token: 0x060095D1 RID: 38353 RVA: 0x0000220F File Offset: 0x0000040F [Token(Token = "0x60095D1")] [Address(RVA = "0x1C34F60", Offset = "0x1C33D60", VA = "0x181C34F60")] private bool IsTransportSupported(string transportName) { throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method."); } // Token: 0x060095D2 RID: 38354 RVA: 0x001ECDC4 File Offset: 0x001EAFC4 [Token(Token = "0x60095D2")] [Address(RVA = "0x1C359B0", Offset = "0x1C347B0", VA = "0x181C359B0")] private void OnNegotiationRequestFinished(NEBIGEDJGPP req, HOOILIHKMEG resp) { while (this.k__BackingField != ConnectionStates.CloseInitiated) { string text = req.GLGCGFDLEJE(); if (text == 0) { if (!resp.HIOBKPKOMLL) { int num = resp.LLODNIOIDKE; string text2 = resp.DFPPNHINEFO; string text3 = resp.DKPCLPHKFDI; int num2; string text4 = string.Format("Negotiation Request Finished Successfully, but the server sent an error. Status Code: {0}-{1} Message: {2}", num2, text2, text3); } ILogger logger = HTTPManager.Logger; string text5 = resp.DKPCLPHKFDI; string text6 = "Negotiation Request Finished Successfully! Response: " + text5; int num3 = 0; NegotiationResult negotiationResult = NegotiationResult.Parse(resp.DKPCLPHKFDI, num3, this); this.k__BackingField = negotiationResult; if (negotiationResult == 0) { continue; } Uri k__BackingField = this.k__BackingField.k__BackingField; int num4 = 0; if (!(k__BackingField != num4)) { this.ConnectImpl(); } int num5 = 0; this.SetState(ConnectionStates.Redirected, num5); int num6 = this.k__BackingField; num6++; this.k__BackingField = num6; HubOptions hubOptions = this.k__BackingField; int k__BackingField = hubOptions.k__BackingField; if (num6 < k__BackingField) { Uri uri = this.k__BackingField; NegotiationResult negotiationResult2 = this.k__BackingField; Uri k__BackingField2 = negotiationResult2.k__BackingField; this.k__BackingField = k__BackingField2; if (!string.IsNullOrEmpty(negotiationResult2.k__BackingField)) { string k__BackingField = this.k__BackingField.k__BackingField; BearerTokenAuthProvider bearerTokenAuthProvider; bearerTokenAuthProvider.StartAuthentication(); bearerTokenAuthProvider.accessToken = k__BackingField; this.k__BackingField = bearerTokenAuthProvider; } if (this.OnRedirected != (ulong)0L) { Action onRedirected = this.OnRedirected; Uri uri2 = this.k__BackingField; onRedirected(this, uri, uri2); ILogger logger2 = HTTPManager.Logger; } this.StartConnect(); } string text7 = string.Format("MaxRedirects ({0:N0}) reached!", hubOptions); } if ("Negotiation Request: " + text != 0) { break; } return; } int num7 = 0; this.SetState(ConnectionStates.Closed, num7); } // Token: 0x060095D3 RID: 38355 RVA: 0x001ECF7C File Offset: 0x001EB17C [Token(Token = "0x60095D3")] [Address(RVA = "0x1C36C90", Offset = "0x1C35A90", VA = "0x181C36C90")] public void StartClose() { ILogger logger = HTTPManager.Logger; int num = 0; this.SetState(ConnectionStates.CloseInitiated, num); if (this.k__BackingField != 0) { } } // Token: 0x060095D4 RID: 38356 RVA: 0x001ECFAC File Offset: 0x001EB1AC [Token(Token = "0x60095D4")] [Address(RVA = "0x1779D80", Offset = "0x1778B80", VA = "0x181779D80")] public IFuture> Stream(string target, params object[] args) { Action action; ulong num2; long num = this.InvokeImp(target, args, action, num2 != 0UL); throw new NullReferenceException(); } // Token: 0x060095D5 RID: 38357 RVA: 0x001ECFCC File Offset: 0x001EB1CC [Token(Token = "0x60095D5")] [Address(RVA = "0x1B557B0", Offset = "0x1B545B0", VA = "0x181B557B0")] public void CancelStream(StreamItemContainer container) { container.IsCanceled = true; } // Token: 0x060095D6 RID: 38358 RVA: 0x001ECFEC File Offset: 0x001EB1EC [Token(Token = "0x60095D6")] [Address(RVA = "0x1779C50", Offset = "0x1778A50", VA = "0x181779C50")] public IFuture Invoke(string target, params object[] args) { Action action; ulong num2; long num = this.InvokeImp(target, args, action, num2 != 0UL); throw new NullReferenceException(); } // Token: 0x060095D7 RID: 38359 RVA: 0x001ED00C File Offset: 0x001EB20C [Token(Token = "0x60095D7")] [Address(RVA = "0x1C36180", Offset = "0x1C34F80", VA = "0x181C36180")] public IFuture Send(string target, params object[] args) { Future future4 = new Future(); Future future = future4; Action action = delegate(Message message) { int num2 = 0; Future future3 = future; Exception ex = new Exception(num2); future3.Fail(ex); }; if (this.k__BackingField == ConnectionStates.Connected && action != 0) { long num; this.invocations.Add(num, action); } Future future2 = future; throw new NullReferenceException(); } // Token: 0x060095D8 RID: 38360 RVA: 0x001ED068 File Offset: 0x001EB268 [Token(Token = "0x60095D8")] [Address(RVA = "0x1C34E00", Offset = "0x1C33C00", VA = "0x181C34E00")] private long InvokeImp(string target, object[] args, Action callback, bool isStreamingInvocation = false) { if (this.k__BackingField == ConnectionStates.Connected && callback != 0) { long num; this.invocations.Add(num, callback); } throw new NullReferenceException(); } // Token: 0x060095D9 RID: 38361 RVA: 0x001ED098 File Offset: 0x001EB298 [Token(Token = "0x60095D9")] [Address(RVA = "0x1C36040", Offset = "0x1C34E40", VA = "0x181C36040")] private void SendMessage(Message message) { IProtocol protocol = this.k__BackingField; int num = 0; num += num; num++; bool nonblocking = message.nonblocking; object[] arguments = message.arguments; object result = message.result; ITransport transport = this.k__BackingField; DateTime utcNow = DateTime.UtcNow; this.lastMessageSent = utcNow; } // Token: 0x060095DA RID: 38362 RVA: 0x001ED0EC File Offset: 0x001EB2EC [Token(Token = "0x60095DA")] [Address(RVA = "0x1C35D80", Offset = "0x1C34B80", VA = "0x181C35D80")] public void On(string methodName, Action callback) { Action action = delegate(object[] args) { callback(); }; Dictionary dictionary = this.subscriptions; bool flag; if (!flag) { Dictionary dictionary2 = this.subscriptions; List list = new List(1); Subscription subscription; subscription.callbacks = list; dictionary2.Add(methodName, subscription); } } // Token: 0x060095DB RID: 38363 RVA: 0x001ED148 File Offset: 0x001EB348 [Token(Token = "0x60095DB")] [Address(RVA = "0x1B55F30", Offset = "0x1B54D30", VA = "0x181B55F30")] public void On(string methodName, Action callback) { Type[] array = new Type[1]; Type typeFromHandle = typeof(Type); if (typeFromHandle != 0) { } array[0] = typeFromHandle; Action action; this.On(methodName, array, action); } // Token: 0x060095DC RID: 38364 RVA: 0x001ED184 File Offset: 0x001EB384 [Token(Token = "0x60095DC")] [Address(RVA = "0x1B55D50", Offset = "0x1B54B50", VA = "0x181B55D50")] public void On(string methodName, Action callback) { Type[] array = new Type[2]; Type typeFromHandle = typeof(Type); if (typeFromHandle != 0) { } array[0] = typeFromHandle; Type type; if (type != 0) { } array[1] = type; Action action; this.On(methodName, array, action); } // Token: 0x060095DD RID: 38365 RVA: 0x001ED1CC File Offset: 0x001EB3CC [Token(Token = "0x60095DD")] [Address(RVA = "0x1B55B10", Offset = "0x1B54910", VA = "0x181B55B10")] public void On(string methodName, Action callback) { Type[] array = new Type[3]; Type typeFromHandle = typeof(Type); if (typeFromHandle != 0) { } array[0] = typeFromHandle; Type type; if (type != 0) { } array[1] = type; Type type2; if (type2 != 0) { } array[2] = type2; Action action; this.On(methodName, array, action); } // Token: 0x060095DE RID: 38366 RVA: 0x001ED220 File Offset: 0x001EB420 [Token(Token = "0x60095DE")] [Address(RVA = "0x1B55870", Offset = "0x1B54670", VA = "0x181B55870")] public void On(string methodName, Action callback) { Type[] array = new Type[4]; Type typeFromHandle = typeof(Type); if (typeFromHandle != 0) { } array[0] = typeFromHandle; Type type; if (type != 0) { } array[1] = type; Type type2; if (type2 != 0) { } array[2] = type2; Type type3; if (type3 != 0) { } array[3] = type3; Action action; this.On(methodName, array, action); } // Token: 0x060095DF RID: 38367 RVA: 0x001ED284 File Offset: 0x001EB484 [Token(Token = "0x60095DF")] [Address(RVA = "0x1C35F10", Offset = "0x1C34D10", VA = "0x181C35F10")] public void On(string methodName, Type[] paramTypes, Action callback) { Dictionary dictionary = this.subscriptions; bool flag; if (!flag) { Dictionary dictionary2 = this.subscriptions; List list = new List(1); Subscription subscription; subscription.callbacks = list; dictionary2.Add(methodName, subscription); } } // Token: 0x060095E0 RID: 38368 RVA: 0x001ED2C4 File Offset: 0x001EB4C4 [Token(Token = "0x60095E0")] [Address(RVA = "0x1C352B0", Offset = "0x1C340B0", VA = "0x181C352B0")] internal void OnMessages(List messages) { ThrowHelper.ThrowArgumentOutOfRangeException(); bool flag; if (this.OnMessage == 0 || !flag) { } ILogger logger = HTTPManager.Logger; int num = 0; if (logger <= (ulong)6L) { Dictionary dictionary = this.subscriptions; bool flag2; if (flag2 && num < (flag2 ? 1 : 0)) { ThrowHelper.ThrowArgumentOutOfRangeException(); num += 2; num += num; IProtocol protocol = this.k__BackingField; ILogger logger2 = HTTPManager.Logger; ILogger logger3 = HTTPManager.Logger; num++; bool flag3; if (flag3) { Dictionary> dictionary2 = this.invocations; bool flag4; if (flag4) { ILogger logger4 = HTTPManager.Logger; bool flag5; if (flag5) { Dictionary> dictionary3 = this.invocations; bool flag6; if (flag6) { ILogger logger5 = HTTPManager.Logger; } Dictionary> dictionary4 = this.invocations; } } } } } } // Token: 0x060095E1 RID: 38369 RVA: 0x001ED39C File Offset: 0x001EB59C [Token(Token = "0x60095E1")] [Address(RVA = "0x1C372E0", Offset = "0x1C360E0", VA = "0x181C372E0")] private void Transport_OnStateChanged(TransportStates oldState, TransportStates newState) { ILogger logger = HTTPManager.Logger; ILogger logger2 = logger; if (logger != 0) { if (logger != 0) { if (logger == 0) { ITransport transport = this.k__BackingField; goto IL_2B; } if (logger2 == (ulong)1L) { } } return; } IL_2B: throw new NullReferenceException(); } // Token: 0x060095E2 RID: 38370 RVA: 0x001ED3DC File Offset: 0x001EB5DC [Token(Token = "0x60095E2")] [Address(RVA = "0x1C36350", Offset = "0x1C35150", VA = "0x181C36350")] private void SetState(ConnectionStates state, [Optional] string errorReason) { ILogger logger = HTTPManager.Logger; string[] array = new string[7]; if ("SetState - from State: '" != 0) { } array[0] = "SetState - from State: '"; ConnectionStates connectionStates; int num = connectionStates.GetHashCode(); if (num != 0) { } array[1] = num; if ("' to State: '" != 0) { } array[2] = "' to State: '"; int num2; num = num2; if (num != 0) { } array[3] = num; if ("' errorReason: '" != 0) { } array[4] = "' errorReason: '"; if (errorReason != 0) { } array[5] = errorReason; if ("'" != 0) { } array[6] = "'"; string text = string.Concat(array); ILogger logger2 = HTTPManager.Logger; string[] array2 = new string[5]; if ("SetState - from State: '" != 0) { } array2[0] = "SetState - from State: '"; ConnectionStates connectionStates2; int num3 = connectionStates2.GetHashCode(); if (num3 != 0) { } array2[1] = num3; if ("' to State: '" != 0) { } array2[2] = "' to State: '"; int num4; num3 = num4; if (num3 != 0) { } array2[3] = num3; if ("'" != 0) { } array2[4] = "'"; string text2 = string.Concat(array2); if (this.k__BackingField != text2) { this.k__BackingField = text2; if (text2 <= (ulong)6L) { Action onConnected = this.OnConnected; if (onConnected != 0) { onConnected(this); } ILogger logger3 = HTTPManager.Logger; HTTPManager.Heartbeats.Subscribe(this); DateTime utcNow = DateTime.UtcNow; this.lastMessageSent = utcNow; } } } // Token: 0x060095E3 RID: 38371 RVA: 0x001ED5C0 File Offset: 0x001EB7C0 [Token(Token = "0x60095E3")] [Address(RVA = "0x1C34900", Offset = "0x1C33700", VA = "0x181C34900", Slot = "4")] void IHeartbeat.OnHeartbeatUpdate(TimeSpan dif) { if (this.k__BackingField == ConnectionStates.Connected) { TimeSpan k__BackingField = this.k__BackingField.k__BackingField; TimeSpan zero = TimeSpan.Zero; if (k__BackingField != zero) { DateTime utcNow = DateTime.UtcNow; DateTime dateTime = this.lastMessageSent; TimeSpan timeSpan = utcNow - dateTime; TimeSpan k__BackingField2 = this.k__BackingField.k__BackingField; if (timeSpan >= k__BackingField2) { } } } } // Token: 0x0400662A RID: 26154 [Token(Token = "0x400662A")] public static readonly object[] EmptyArgs = new object[0]; // Token: 0x04006638 RID: 26168 [global::Cpp2IlInjected.FieldOffset(Offset = "0x78")] [Token(Token = "0x4006638")] private long lastInvocationId; // Token: 0x04006639 RID: 26169 [global::Cpp2IlInjected.FieldOffset(Offset = "0x80")] [Token(Token = "0x4006639")] private Dictionary> invocations; // Token: 0x0400663A RID: 26170 [global::Cpp2IlInjected.FieldOffset(Offset = "0x88")] [Token(Token = "0x400663A")] private Dictionary subscriptions; // Token: 0x0400663B RID: 26171 [global::Cpp2IlInjected.FieldOffset(Offset = "0x90")] [Token(Token = "0x400663B")] private DateTime lastMessageSent; } }