Skip to content

Class AuthenticationStartedEvent

Namespace: Void.Proxy.Api.Events.Authentication
Assembly: Void.Proxy.Api.dll

Represents the event raised when authentication begins for a linked player connection.

public record AuthenticationStartedEvent : IScopedEventWithResult<AuthenticationResult>, IScopedEvent, IEventWithResult<AuthenticationResult>, IEvent, IEquatable<AuthenticationStartedEvent>

Inheritance

objectAuthenticationStartedEvent

Implements

IScopedEventWithResult<AuthenticationResult>, IScopedEvent, IEventWithResult<AuthenticationResult>, IEvent, IEquatable<AuthenticationStartedEvent>

Inherited Members

object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()

Remarks

The generated record constructor stores these values without additional validation.

Constructors

Represents the event raised when authentication begins for a linked player connection.

public AuthenticationStartedEvent(ILink Link, IPlayer Player, AuthenticationSide Side)

Parameters

Link ILink

The active link that connects the player to the selected server.

Player IPlayer

The player whose authentication flow is starting.

Side AuthenticationSide

The side responsible for handling authentication. indicates that proxy listeners should complete the authentication flow; indicates that the downstream server is expected to handle authentication and proxy authentication listeners should treat the player as authenticated.

Remarks

The generated record constructor stores these values without additional validation.

Properties

The active link that connects the player to the selected server.

public ILink Link { get; init; }

Property Value

ILink

Player

The player whose authentication flow is starting.

public IPlayer Player { get; init; }

Property Value

IPlayer

Result

Gets or sets the authentication decision produced by listeners for this event.

public AuthenticationResult? Result { get; set; }

Property Value

AuthenticationResult?

Examples

var result = await events.ThrowWithResultAsync(authenticationStartedEvent, cancellationToken)
    ?? AuthenticationResult.NoResult;

Remarks

The event dispatcher returns this property from .

Callers commonly coalesce null to to represent an unresolved state.

See Also

AuthenticationResult.NoResult

Side

The side responsible for handling authentication. indicates that proxy listeners should complete the authentication flow; indicates that the downstream server is expected to handle authentication and proxy authentication listeners should treat the player as authenticated.

public AuthenticationSide Side { get; init; }

Property Value

AuthenticationSide