<?php

namespace App\ValueObjects\Communications;

class RenderedMessage
{
    public function __construct(
        public readonly ?string $subject,
        public readonly ?string $bodyText,
        public readonly ?string $bodyHtml,
        public readonly array $placeholdersUsed = [],
        public readonly array $unknownPlaceholders = [],
    ) {}

    public function hasUnknownPlaceholders(): bool
    {
        return !empty($this->unknownPlaceholders);
    }
}
