Protocol/NetworkSlot.cs

A simple data transfer object used for network protocol serialization. It defines a slot with Name, Game, Type and GroupMembers properties and maps them to specific JSON property names.

using System.Text.Json.Serialization;

namespace APLib.Protocol;

public sealed class NetworkSlot
{
	[JsonPropertyName( "name" )]
	public string Name { get; set; }
	
	[JsonPropertyName( "game" )]
	public string Game { get; set; }
	
	[JsonPropertyName( "type" )]
	public int Type { get; set; }
	
	[JsonPropertyName( "group_members" )]
	public int[] GroupMembers { get; set; } = [];
}