PacketMediator/PacketIdAttribute.cs

15 lines
383 B
C#
Raw Normal View History

2024-02-08 11:55:35 +00:00
// Licensed to Timothy Schenk under the GNU AGPL Version 3 License.
namespace Rai.PacketMediator;
[AttributeUsage(AttributeTargets.Class, Inherited = false)]
public abstract class PacketIdAttribute<TPacketIdEnum> : Attribute where TPacketIdEnum : Enum
{
protected PacketIdAttribute(TPacketIdEnum code)
{
Code = code;
}
public TPacketIdEnum Code { get; }
}