public void Dispose() { if (r3Connection != null && r3Connection.IsOpen) { r3Connection.Close(); } r3Connection?.Dispose(); }