diff --git a/src/Infrastructure/IDeleteable.cs b/src/Infrastructure/IDeleteable.cs index 86ae522..970b548 100644 --- a/src/Infrastructure/IDeleteable.cs +++ b/src/Infrastructure/IDeleteable.cs @@ -6,4 +6,35 @@ public interface IDeletable { bool IsDeleted { get; set; } +} + +public interface IPrimaryKey where T : IEquatable +{ + public T Id { get; set; } +} + +public interface IEntityBase : IPrimaryKey, IDeletable where T : IEquatable +{ + public DateTime CreatedDate { get; set; } + + public DateTime? UpdatedDate { get; set; } + + public string? Name { get; set; } + + public T CreatorId { get; set; } +} + +public abstract class EntityBase : IEntityBase where T : class, IEquatable +{ + public bool IsDeleted { get; set; } + + public T Id { get; set; } + + public DateTime CreatedDate { get; set; } + + public string? Name { get; set; } + + public DateTime? UpdatedDate { get; set; } + + public T CreatorId { get; set; } } \ No newline at end of file