fish-station/Content.Shared/_Sunrise/Messenger/MessengerGroup.cs
Vigers Ray 95d7d4d348
ыыыыы, месенжер макс, ихихяхя (#3789)
Co-authored-by: Daniel <77834935+Orvex07@users.noreply.github.com>
2026-01-26 22:44:54 +03:00

50 lines
1.5 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using Robust.Shared.Serialization;
namespace Content.Shared._Sunrise.Messenger;
/// <summary>
/// Информация о группе в мессенджере
/// </summary>
[Serializable, NetSerializable]
public sealed class MessengerGroup
{
/// <summary>
/// Уникальный ID группы
/// </summary>
public string GroupId { get; set; }
/// <summary>
/// Название группы
/// </summary>
public string Name { get; set; }
/// <summary>
/// ID участников группы
/// </summary>
public HashSet<string> Members { get; set; }
/// <summary>
/// Тип группы
/// </summary>
public MessengerGroupType Type { get; set; }
/// <summary>
/// ID прототипа автоматической группы (null для пользовательских групп)
/// </summary>
public string? AutoGroupPrototypeId { get; set; }
/// <summary>
/// ID владельца группы (создателя). null для автоматических групп
/// </summary>
public string? OwnerId { get; set; }
public MessengerGroup(string groupId, string name, HashSet<string> members, MessengerGroupType type = MessengerGroupType.UserCreated, string? autoGroupPrototypeId = null, string? ownerId = null)
{
GroupId = groupId;
Name = name;
Members = members;
Type = type;
AutoGroupPrototypeId = autoGroupPrototypeId;
OwnerId = ownerId;
}
}