<?php declare(strict_types=1); namespace mystic\forum\orm; use mystic\forum\attributes\DefaultValue; use mystic\forum\attributes\PrimaryKey; use mystic\forum\attributes\References; use mystic\forum\attributes\Table; #[Table("public.posts")] class Post extends Entity { #[PrimaryKey] public string $id; public string $content; #[References("public.users", onDelete: References::SET_NULL)] public ?string $authorId; public \DateTimeImmutable $postDate; #[References("public.topics", onDelete: References::CASCADE)] public string $topicId; #[DefaultValue("false")] public bool $deleted; #[DefaultValue("false")] public bool $edited; }