/// <summary> /// Close the counter, releasing the resource managed by the media driver if this was the creator of the Counter. /// <para> /// This method is idempotent. /// </para> /// </summary> public override void Dispose() { if (_isClosed.CompareAndSet(false, true)) { base.Dispose(); _clientConductor?.ReleaseCounter(this); } }
/// <summary> /// Close the counter, releasing the resource managed by the media driver if this was the creator of the Counter. /// <para> /// This method is idempotent. /// </para> /// </summary> public virtual void Close() { if (null != clientConductor) { clientConductor.ReleaseCounter(this); } else { isClosed = true; } }
/// <summary> /// Close the counter, releasing the resource managed by the media driver if this was the creator of the Counter. /// <para> /// This method is idempotent. /// </para> /// </summary> public override void Dispose() { if (null != clientConductor) { clientConductor.ReleaseCounter(this); } else { isClosed = true; } }