ConstrainBooleanOrDomString Struct
The ConstrainBooleanOrDOMString typedef (https://w3c.github.io/mediacapture-main/#dom-constrainbooleanordomstring): a bare value, or an exact and an ideal value.
public readonly struct ConstrainBooleanOrDomString : IEquatable<ConstrainBooleanOrDomString>- Implements
Properties
| Name | Description |
|---|---|
| BareFlag | Gets the bare boolean value when the union holds it, otherwise null. |
| BareText | Gets the bare string value when the union holds it, otherwise null. |
| Parameters | Gets the parameters when the union holds it, otherwise null. |
| Value | Gets the value of the union: Boolean or String or ConstrainBooleanOrDomStringParameters. |
BareFlag
MediaCaptureUnions.csBareText
MediaCaptureUnions.csParameters
MediaCaptureUnions.csGets the parameters when the union holds it, otherwise null.
public ConstrainBooleanOrDomStringParameters? Parameters { get; }Property value
Gets the value of the union: Boolean or String or ConstrainBooleanOrDomStringParameters.
public object Value { get; }Property value
Methods
| Name | Description |
|---|---|
| Equals(ConstrainBooleanOrDomString) | 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 bare boolean value. |
| FromConstrainBooleanOrDomStringParameters(ConstrainBooleanOrDomStringParameters) | Creates the union from the parameters. |
| FromString(string) | Creates the union from the bare string value. |
| GetHashCode() | Returns the hash code for this instance. |
Equals overloads
Equals(ConstrainBooleanOrDomString)
MediaCaptureUnions.csIndicates whether the current object is equal to another object of the same type.
public bool Equals(ConstrainBooleanOrDomString other)Parameters
otherConstrainBooleanOrDomString- 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 bare boolean value.
public static ConstrainBooleanOrDomString FromBoolean(bool value)FromConstrainBooleanOrDomStringParameters(ConstrainBooleanOrDomStringParameters)
MediaCaptureUnions.csCreates the union from the parameters.
public static ConstrainBooleanOrDomString FromConstrainBooleanOrDomStringParameters(ConstrainBooleanOrDomStringParameters value)FromString(string)
MediaCaptureUnions.csCreates the union from the bare string value.
public static ConstrainBooleanOrDomString FromString(string value)GetHashCode()
MediaCaptureUnions.csOperators
| Name | Description |
|---|---|
| operator ==(ConstrainBooleanOrDomString, ConstrainBooleanOrDomString) | Returns whether the two unions hold the same value. |
| implicit operator ConstrainBooleanOrDomString(ConstrainBooleanOrDomStringParameters) | Creates the union from the parameters. |
| implicit operator ConstrainBooleanOrDomString(bool) | Creates the union from the bare boolean value. |
| implicit operator ConstrainBooleanOrDomString(string) | Creates the union from the bare string value. |
| operator !=(ConstrainBooleanOrDomString, ConstrainBooleanOrDomString) | Returns whether the two unions hold different values. |
operator ==(ConstrainBooleanOrDomString, ConstrainBooleanOrDomString)
MediaCaptureUnions.csReturns whether the two unions hold the same value.
public static bool operator ==(ConstrainBooleanOrDomString left, ConstrainBooleanOrDomString right)op_Implicit overloads
implicit operator ConstrainBooleanOrDomString(ConstrainBooleanOrDomStringParameters)
MediaCaptureUnions.csCreates the union from the parameters.
public static implicit operator ConstrainBooleanOrDomString(ConstrainBooleanOrDomStringParameters value)implicit operator ConstrainBooleanOrDomString(bool)
MediaCaptureUnions.csCreates the union from the bare boolean value.
public static implicit operator ConstrainBooleanOrDomString(bool value)implicit operator ConstrainBooleanOrDomString(string)
MediaCaptureUnions.csCreates the union from the bare string value.
public static implicit operator ConstrainBooleanOrDomString(string value)operator !=(ConstrainBooleanOrDomString, ConstrainBooleanOrDomString)
MediaCaptureUnions.csReturns whether the two unions hold different values.
public static bool operator !=(ConstrainBooleanOrDomString left, ConstrainBooleanOrDomString right)