BooleanOrString Struct
The (boolean or DOMString) union of the echoCancellation constrainable property: a boolean, or an echo cancellation mode (all, remote-only).
public readonly struct BooleanOrString : IEquatable<BooleanOrString>- Implements
Properties
| Name | Description |
|---|---|
| Flag | Gets the boolean when the union holds it, otherwise null. |
| Text | Gets the string when the union holds it, otherwise null. |
| Value | Gets the value of the union: Boolean or String. |
Methods
| Name | Description |
|---|---|
| Equals(BooleanOrString) | Indicates whether the current object is equal to another object of the same type. |
| Equals(object?) | Indicates whether this instance and a specified object are equal. |
| FromBoolean(bool) | Creates the union from the boolean. |
| FromString(string) | Creates the union from the string. |
| GetHashCode() | Returns the hash code for this instance. |
Equals overloads
Equals(BooleanOrString)
MediaCaptureUnions.csIndicates whether the current object is equal to another object of the same type.
public bool Equals(BooleanOrString other)Parameters
otherBooleanOrString- An object to compare with this object.
Returns
bool true if the current object is equal to the other parameter; otherwise, false.
Equals(object?)
MediaCaptureUnions.csFromBoolean(bool)
MediaCaptureUnions.csCreates the union from the boolean.
public static BooleanOrString FromBoolean(bool value)FromString(string)
MediaCaptureUnions.csCreates the union from the string.
public static BooleanOrString FromString(string value)GetHashCode()
MediaCaptureUnions.csOperators
| Name | Description |
|---|---|
| operator ==(BooleanOrString, BooleanOrString) | Returns whether the two unions hold the same value. |
| implicit operator BooleanOrString(bool) | Creates the union from the boolean. |
| implicit operator BooleanOrString(string) | Creates the union from the string. |
| operator !=(BooleanOrString, BooleanOrString) | Returns whether the two unions hold different values. |
operator ==(BooleanOrString, BooleanOrString)
MediaCaptureUnions.csReturns whether the two unions hold the same value.
public static bool operator ==(BooleanOrString left, BooleanOrString right)op_Implicit overloads
implicit operator BooleanOrString(bool)
MediaCaptureUnions.csCreates the union from the boolean.
public static implicit operator BooleanOrString(bool value)implicit operator BooleanOrString(string)
MediaCaptureUnions.csCreates the union from the string.
public static implicit operator BooleanOrString(string value)operator !=(BooleanOrString, BooleanOrString)
MediaCaptureUnions.csReturns whether the two unions hold different values.
public static bool operator !=(BooleanOrString left, BooleanOrString right)