continuity/Rai.PacketMediator/PacketIdAttribute.cs

14 lines
348 B
C#

// Copyright (c) 2023 Timothy Schenk. Subject to the GNU AGPL Version 3 License.
namespace Rai.PacketMediator;
[AttributeUsage(AttributeTargets.Class, Inherited = false)]
public abstract class PacketIdAttribute<T> : Attribute where T : Enum
{
protected PacketIdAttribute(T code)
{
Code = code;
}
public T Code { get; }
}