CommunicationObject.ThrowIfDisposedOrImmutable Method

Definition

Throws an exception if the communication object the State property is not set to the Created state.

protected:
 void ThrowIfDisposedOrImmutable();
protected void ThrowIfDisposedOrImmutable ();
member this.ThrowIfDisposedOrImmutable : unit -> unit
Protected Sub ThrowIfDisposedOrImmutable ()

Exceptions

The communication object is in a Opening or Opened state.

The communication object is in a Closing or Closed state.

The communication object is in a Faulted state.

Remarks

Since an object is immutable after Open is called on it, the only state that is both mutable and not disposed is the Created state.

Applies to