SanitizerOrSanitizerConfigOrSanitizerPresets Struct

The (Sanitizer or SanitizerConfig or SanitizerPresets) union.

public readonly struct SanitizerOrSanitizerConfigOrSanitizerPresets : IEquatable<SanitizerOrSanitizerConfigOrSanitizerPresets>
Implements

Properties

NameDescription
SanitizerGets the value as a sanitizer, or null when the union holds another type.
SanitizerConfigGets the value as a sanitizer configuration, or null when the union holds another type.
SanitizerPresetsGets the value as a sanitizer preset, or null when the union holds another type.
ValueGets the value of the union: a sanitizer or a sanitizer configuration or a sanitizer preset.

Gets the value as a sanitizer, or null when the union holds another type.

public Sanitizer? Sanitizer { get; }

Property value

Sanitizer?

SanitizerConfig

SanitizerTypes.cs

Gets the value as a sanitizer configuration, or null when the union holds another type.

public SanitizerConfig? SanitizerConfig { get; }

Property value

SanitizerConfig?

SanitizerPresets

SanitizerTypes.cs

Gets the value as a sanitizer preset, or null when the union holds another type.

public SanitizerPresets? SanitizerPresets { get; }

Property value

SanitizerPresets?

Gets the value of the union: a sanitizer or a sanitizer configuration or a sanitizer preset.

public object Value { get; }

Property value

object

Methods

NameDescription
Equals(SanitizerOrSanitizerConfigOrSanitizerPresets)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.
FromSanitizer(Sanitizer)Creates the union from a sanitizer.
FromSanitizerConfig(SanitizerConfig)Creates the union from a sanitizer configuration.
FromSanitizerPresets(SanitizerPresets)Creates the union from a sanitizer preset.
GetHashCode()Returns the hash code for this instance.

Equals overloads

Equals(SanitizerOrSanitizerConfigOrSanitizerPresets)

SanitizerTypes.cs

Indicates whether the current object is equal to another object of the same type.

Parameters
other SanitizerOrSanitizerConfigOrSanitizerPresets
An object to compare with this object.
Returns

bool true if the current object is equal to the other parameter; otherwise, false.

Equals(object?)

SanitizerTypes.cs

Indicates whether this instance and a specified object are equal.

public override bool Equals(object? obj)
Parameters
obj object?
The object to compare with the current instance.
Returns

bool true if obj and this instance are the same type and represent the same value; otherwise, false.

FromSanitizer(Sanitizer)

SanitizerTypes.cs

Creates the union from a sanitizer.

public static SanitizerOrSanitizerConfigOrSanitizerPresets FromSanitizer(Sanitizer value)

FromSanitizerConfig(SanitizerConfig)

SanitizerTypes.cs

Creates the union from a sanitizer configuration.

public static SanitizerOrSanitizerConfigOrSanitizerPresets FromSanitizerConfig(SanitizerConfig value)

FromSanitizerPresets(SanitizerPresets)

SanitizerTypes.cs

Creates the union from a sanitizer preset.

public static SanitizerOrSanitizerConfigOrSanitizerPresets FromSanitizerPresets(SanitizerPresets value)

GetHashCode()

SanitizerTypes.cs

Returns the hash code for this instance.

public override int GetHashCode()

Returns

int A 32-bit signed integer that is the hash code for this instance.

Operators

NameDescription
operator ==(SanitizerOrSanitizerConfigOrSanitizerPresets, SanitizerOrSanitizerConfigOrSanitizerPresets)Determines whether two unions are equal.
implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(Sanitizer)Converts a sanitizer to the union.
implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(SanitizerConfig)Converts a sanitizer configuration to the union.
implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(SanitizerPresets)Converts a sanitizer preset to the union.
operator !=(SanitizerOrSanitizerConfigOrSanitizerPresets, SanitizerOrSanitizerConfigOrSanitizerPresets)Determines whether two unions are different.

operator ==(SanitizerOrSanitizerConfigOrSanitizerPresets, SanitizerOrSanitizerConfigOrSanitizerPresets)

SanitizerTypes.cs

op_Implicit overloads

implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(Sanitizer)

SanitizerTypes.cs

Converts a sanitizer to the union.

public static implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(Sanitizer value)

implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(SanitizerConfig)

SanitizerTypes.cs

Converts a sanitizer configuration to the union.

public static implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(SanitizerConfig value)

implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(SanitizerPresets)

SanitizerTypes.cs

Converts a sanitizer preset to the union.

public static implicit operator SanitizerOrSanitizerConfigOrSanitizerPresets(SanitizerPresets value)

operator !=(SanitizerOrSanitizerConfigOrSanitizerPresets, SanitizerOrSanitizerConfigOrSanitizerPresets)

SanitizerTypes.cs