protected override void CloseImplementation(SocketCloseCode code, string reason) { if (_socket != null) { OnTrace(XenLogLevel.Info, $"Closing connection to {Endpoint}."); var status = CloseStatusCode.Undefined; switch (code) { case SocketCloseCode.Normal: status = CloseStatusCode.Normal; break; case SocketCloseCode.Undefined: status = CloseStatusCode.Undefined; break; case SocketCloseCode.UnsupportedData: status = CloseStatusCode.UnsupportedData; break; } _socket.Close(status, reason); } }
protected override void CloseImplementation(SocketCloseCode code, string reason) { }
protected abstract void CloseImplementation(SocketCloseCode code, string reason);
/// <summary> /// Close the current connection to a <see cref="DesignServer"/> /// </summary> /// <param name="code"></param> /// <param name="reason"></param> public virtual void Close(SocketCloseCode code, string reason) { CloseImplementation(code, reason); }