hn-dotnet/Domain/Comment.cs
2020-12-10 18:37:46 +01:00

20 lines
435 B
C#

using System;
namespace HN.Domain
{
public sealed class Comment
{
public Guid Id { get; private set; }
public Guid LinkId { get; private set; }
public string Content { get; private set; }
public DateTime CreatedAt { get; private set; }
internal Comment(Guid linkId, string content)
{
Id = Guid.NewGuid();
LinkId = linkId;
Content = content;
CreatedAt = DateTime.UtcNow;
}
}
}