UnicodeCharacterInfo Struct

Represents Unicode character information.

public readonly struct UnicodeCharacterInfo : IEquatable<UnicodeCharacterInfo>

Remarks

A default instance, such as the value returned by a failed TryGetCharacterInfo call, describes no character: its UnicodeCharacterInfo.Name is empty, its UnicodeCharacterInfo.Block is UnicodeBlocks.Unknown, the nullable properties are null, and it is not equal to the entry for U+0000.

Implements

Properties

NameDescription
BidiCategoryGets the Unicode bidirectional category.
BlockGets the Unicode block.
CanonicalCombiningClassGets the canonical combining class.
CategoryGets the Unicode general category.
DecimalDigitValueGets the decimal digit value.
DecompositionMappingGets the decomposition mapping.
DigitValueGets the digit value.
HasEmojiPresentationGets a value indicating whether the character has the Emoji_Presentation property.
IsEmojiGets a value indicating whether the character has the Emoji property.
IsEmojiComponentGets a value indicating whether the character has the Emoji_Component property.
IsEmojiModifierGets a value indicating whether the character has the Emoji_Modifier property.
IsEmojiModifierBaseGets a value indicating whether the character has the Emoji_Modifier_Base property.
IsExtendedPictographicGets a value indicating whether the character has the Extended_Pictographic property.
IsMirroredGets a value indicating whether the character is mirrored.
IsoCommentGets the ISO comment.
NameGets the character name.
NumericValueGets the numeric value.
RuneGets the Unicode scalar value.
SimpleLowercaseMappingGets the simple lowercase mapping.
SimpleTitlecaseMappingGets the simple titlecase mapping.
SimpleUppercaseMappingGets the simple uppercase mapping.
Unicode1NameGets the Unicode 1.0 name.

Gets the Unicode bidirectional category.

public UnicodeBidirectionalCategory BidiCategory { get; }

Gets the Unicode block.

public UnicodeBlock Block { get; }

Property value

UnicodeBlock The Unicode block, or UnicodeBlocks.Unknown for a default instance.

CanonicalCombiningClass

UnicodeCharacterInfo.cs

Gets the canonical combining class.

public byte CanonicalCombiningClass { get; }

Property value

byte

Gets the Unicode general category.

public UnicodeCategory Category { get; }

Property value

UnicodeCategory

DecimalDigitValue

UnicodeCharacterInfo.cs

Gets the decimal digit value.

public int? DecimalDigitValue { get; }

Property value

int?

DecompositionMapping

UnicodeCharacterInfo.cs

Gets the decomposition mapping.

public string? DecompositionMapping { get; }

Property value

string?

Gets the digit value.

public int? DigitValue { get; }

Property value

int?

HasEmojiPresentation

UnicodeCharacterInfo.cs

Gets a value indicating whether the character has the Emoji_Presentation property.

public bool HasEmojiPresentation { get; }

Property value

bool

Gets a value indicating whether the character has the Emoji property.

public bool IsEmoji { get; }

Property value

bool

IsEmojiComponent

UnicodeCharacterInfo.cs

Gets a value indicating whether the character has the Emoji_Component property.

public bool IsEmojiComponent { get; }

Property value

bool

Gets a value indicating whether the character has the Emoji_Modifier property.

public bool IsEmojiModifier { get; }

Property value

bool

IsEmojiModifierBase

UnicodeCharacterInfo.cs

Gets a value indicating whether the character has the Emoji_Modifier_Base property.

public bool IsEmojiModifierBase { get; }

Property value

bool

IsExtendedPictographic

UnicodeCharacterInfo.cs

Gets a value indicating whether the character has the Extended_Pictographic property.

public bool IsExtendedPictographic { get; }

Property value

bool

Gets a value indicating whether the character is mirrored.

public bool IsMirrored { get; }

Property value

bool

Gets the ISO comment.

public string? IsoComment { get; }

Property value

string?

Gets the character name.

public string Name { get; }

Property value

string The character name, or an empty string for a default instance.

Gets the numeric value.

public string? NumericValue { get; }

Property value

string?

Gets the Unicode scalar value.

public Rune Rune { get; }

Property value

Rune

SimpleLowercaseMapping

UnicodeCharacterInfo.cs

Gets the simple lowercase mapping.

public Rune? SimpleLowercaseMapping { get; }

Property value

Rune?

SimpleTitlecaseMapping

UnicodeCharacterInfo.cs

Gets the simple titlecase mapping.

public Rune? SimpleTitlecaseMapping { get; }

Property value

Rune?

SimpleUppercaseMapping

UnicodeCharacterInfo.cs

Gets the simple uppercase mapping.

public Rune? SimpleUppercaseMapping { get; }

Property value

Rune?

Gets the Unicode 1.0 name.

public string? Unicode1Name { get; }

Property value

string?

Methods

NameDescription
Equals(UnicodeCharacterInfo)Determines whether this instance and another describe the same Unicode character.
Equals(object?)
GetHashCode()

Equals overloads

Equals(UnicodeCharacterInfo)

UnicodeCharacterInfo.cs

Determines whether this instance and another describe the same Unicode character.

public bool Equals(UnicodeCharacterInfo other)
Parameters
other UnicodeCharacterInfo
The other character information.
Returns

bool true when both describe the same character; otherwise false.

Remarks

Instances come from a fixed table keyed by UnicodeCharacterInfo.Rune, so the scalar value identifies the entry. The index of the property record is compared as well so that a default instance, which carries the scalar value U+0000 and no properties, is not equal to the real entry for U+0000.

public override bool Equals(object? obj)
Parameters
obj object?
Returns

bool

No documentation is available.

public override int GetHashCode()

Returns

int

No documentation is available.

Operators

NameDescription
operator ==(UnicodeCharacterInfo, UnicodeCharacterInfo)
operator !=(UnicodeCharacterInfo, UnicodeCharacterInfo)

operator ==(UnicodeCharacterInfo, UnicodeCharacterInfo)

UnicodeCharacterInfo.cs
public static bool operator ==(UnicodeCharacterInfo left, UnicodeCharacterInfo right)

No documentation is available.

operator !=(UnicodeCharacterInfo, UnicodeCharacterInfo)

UnicodeCharacterInfo.cs
public static bool operator !=(UnicodeCharacterInfo left, UnicodeCharacterInfo right)

No documentation is available.