private void FinishRequest(TimeSpan?result, ErrorInfo error) { if (_finished == false) { lock (_syncLock) { if (_finished == false) { _finished = true; _manager.MessageReceived -= OnMessageReceived; _manager.Connection.InternalStateChanged -= OnInternalStateChanged; _timer.Abort(); _callback?.Invoke(result, error); _callback = null; _manager = null; _timer = null; } } } }
private void TransitionState(ConnectionState newState) { this.context.SetState(newState); _timer.Abort(); }
private void TransitionState(RealtimeCommand command) { _timer.Abort(); Context.ExecuteCommand(command); }
public override void Close() { _timer.Abort(); Context.ExecuteCommand(SetClosedStateCommand.Create().TriggeredBy("SuspendedState.Close()")); }
public override void AbortTimer() { _timer.Abort(); }
public override void Close() { _timer.Abort(); Context.SetState(new ConnectionClosedState(Context, Logger)); }