2024-02-26 12:18:04 +00:00
|
|
|
// Licensed to Timothy Schenk under the Apache 2.0 License.
|
2024-02-08 11:55:35 +00:00
|
|
|
|
2024-04-04 14:32:04 +00:00
|
|
|
namespace RaiNote.PacketMediator;
|
2024-02-08 11:55:35 +00:00
|
|
|
|
|
|
|
[AttributeUsage(AttributeTargets.Class, Inherited = false)]
|
|
|
|
public abstract class PacketIdAttribute<TPacketIdEnum> : Attribute where TPacketIdEnum : Enum
|
|
|
|
{
|
|
|
|
protected PacketIdAttribute(TPacketIdEnum code)
|
|
|
|
{
|
|
|
|
Code = code;
|
|
|
|
}
|
|
|
|
|
|
|
|
public TPacketIdEnum Code { get; }
|
|
|
|
}
|