Table of Contents

Class CompositeValidator<T>

Namespace
SteamNetworkLib.Sync
Assembly
SteamNetworkLib.dll

Validator that combines multiple validators with AND logic.

public class CompositeValidator<T> : ISyncValidator<T>

Type Parameters

T
Inheritance
CompositeValidator<T>
Implements
Inherited Members

Constructors

CompositeValidator(params ISyncValidator<T>[])

Creates a composite validator that requires all validators to pass.

public CompositeValidator(params ISyncValidator<T>[] validators)

Parameters

validators ISyncValidator<T>[]

Array of validators to check.

Methods

GetErrorMessage(T)

Gets a human-readable error message describing why validation failed.

public string? GetErrorMessage(T value)

Parameters

value T

The invalid value.

Returns

string

An error message, or null if no specific message is available.

IsValid(T)

Validates a value before it is synchronized.

public bool IsValid(T value)

Parameters

value T

The value to validate.

Returns

bool

True if the value is valid, false otherwise.