using MemoryPack;

namespace Insight.Agent.Messages
{
    [MemoryPackUnion(11, typeof(Trap))]
    public partial interface IAgentMessage { }

    [MemoryPackable]
    public partial class Trap : IAgentMessage
    {
        [MemoryPackOrder(0)]
        public DateTime? Timestamp { get; set; }

        [MemoryPackOrder(1)]
        public string? Endpoint { get; set; }

        [MemoryPackOrder(2)]
        public string? Hostname { get; set; }

        [MemoryPackOrder(3)]
        public string? Version { get; set; }

        [MemoryPackOrder(4)]
        public string? Community { get; set; }

        [MemoryPackOrder(5)]
        public List<KeyValuePair<string, string?>>? Data { get; set; }
    }
}