Table of Contents

Class UserId

Namespace
NetCord.Services
Assembly
NetCord.Services.dll

Represents a user ID with an optional user object.

public class UserId : Entity, IEntity, IEquatable<Entity>, ISpanFormattable, IFormattable
Inheritance
UserId
Implements
Inherited Members

Constructors

UserId(ulong)

Represents a user ID with an optional user object.

public UserId(ulong id)

Parameters

id ulong
The ID of the user.

UserId(ulong, User?)

Represents a user ID with an optional user object.
public UserId(ulong id, User? user)

Parameters

id ulong
The ID of the user.
user User
The user object, if available.

Properties

Id

The ID of the user.

public override ulong Id { get; }

Property Value

ulong

User

The user object, if available.

public User? User { get; }

Property Value

User

Methods

ToString()

public override string ToString()

Returns

string

TryFormat(Span<char>, out int, ReadOnlySpan<char>, IFormatProvider?)

public override bool TryFormat(Span<char> destination, out int charsWritten, ReadOnlySpan<char> format = default, IFormatProvider? provider = null)

Parameters

destination Span<char>
charsWritten int
format ReadOnlySpan<char>
provider IFormatProvider

Returns

bool