//-----------------------------------------------------------------------
//
// Copyright (c) aliasvault. All rights reserved.
// Licensed under the AGPLv3 license. See LICENSE.md file in the project root for full license information.
//
//-----------------------------------------------------------------------
namespace AliasServerDb;
using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
///
/// Represents a log entry in the AliasServerDb.
///
public class Log
{
///
/// Gets or sets the unique identifier of the log entry.
///
[Key]
public int Id { get; set; }
///
/// Gets or sets the application name associated with the log entry.
///
[Required]
[MaxLength(50)]
public string Application { get; set; } = null!;
///
/// Gets or sets the source context that triggered this log message.
///
[MaxLength(255)]
public string SourceContext { get; set; } = null!;
///
/// Gets or sets the log message.
///
public string Message { get; set; } = null!;
///
/// Gets or sets the message template for the log entry.
///
public string MessageTemplate { get; set; } = null!;
///
/// Gets or sets the log level.
///
[MaxLength(128)]
public string Level { get; set; } = null!;
///
/// Gets or sets the timestamp of the log entry.
///
public DateTime TimeStamp { get; set; }
///
/// Gets or sets the exception associated with the log entry.
///
public string Exception { get; set; } = null!;
///
/// Gets or sets the additional properties of the log entry.
///
public string Properties { get; set; } = null!;
///
/// Gets or sets the log event.
///
[Column("LogEvent")]
public string LogEvent { get; set; } = null!;
}