CssKeywordish Struct

The CSSKeywordish typedef: (DOMString or CSSKeywordValue) (https://drafts.css-houdini.org/css-typed-om-1/#typedefdef-csskeywordish).

public readonly struct CssKeywordish : IEquatable<CssKeywordish>
Implements

Properties

NameDescription
ValueGets the value: a String or a CssKeywordValue.

Gets the value: a String or a CssKeywordValue.

public object Value { get; }

Property value

object

Methods

NameDescription
Equals(CssKeywordish)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.
FromCssKeywordValue(CssKeywordValue)Creates a CssKeywordish from a CssKeywordValue.
FromString(string)Creates a CssKeywordish from a string.
GetHashCode()Returns the hash code for this instance.

Equals overloads

Equals(CssKeywordish)

CssColorValue.cs

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

public bool Equals(CssKeywordish other)
Parameters
other CssKeywordish
An object to compare with this object.
Returns

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

Equals(object?)

CssColorValue.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.

FromCssKeywordValue(CssKeywordValue)

CssColorValue.cs

Creates a CssKeywordish from a CssKeywordValue.

public static CssKeywordish FromCssKeywordValue(CssKeywordValue value)

Parameters

value CssKeywordValue

Returns

CssKeywordish

FromString(string)

CssColorValue.cs

Creates a CssKeywordish from a string.

public static CssKeywordish FromString(string value)

Parameters

value string

Returns

CssKeywordish

GetHashCode()

CssColorValue.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 ==(CssKeywordish, CssKeywordish)Determines whether two CssKeywordish values are equal.
implicit operator CssKeywordish(CssKeywordValue)Converts a CssKeywordValue to a CssKeywordish.
implicit operator CssKeywordish(string)Converts a string to a CssKeywordish.
operator !=(CssKeywordish, CssKeywordish)Determines whether two CssKeywordish values are not equal.

operator ==(CssKeywordish, CssKeywordish)

CssColorValue.cs

Determines whether two CssKeywordish values are equal.

public static bool operator ==(CssKeywordish left, CssKeywordish right)

Parameters

left CssKeywordish
right CssKeywordish

Returns

bool

op_Implicit overloads

implicit operator CssKeywordish(CssKeywordValue)

CssColorValue.cs

Converts a CssKeywordValue to a CssKeywordish.

public static implicit operator CssKeywordish(CssKeywordValue value)
Parameters
value CssKeywordValue
Returns

CssKeywordish

implicit operator CssKeywordish(string)

CssColorValue.cs

Converts a string to a CssKeywordish.

public static implicit operator CssKeywordish(string value)
Parameters
value string
Returns

CssKeywordish

operator !=(CssKeywordish, CssKeywordish)

CssColorValue.cs

Determines whether two CssKeywordish values are not equal.

public static bool operator !=(CssKeywordish left, CssKeywordish right)

Parameters

left CssKeywordish
right CssKeywordish

Returns

bool