<?php

namespace App\Domain\Manga\Domain\Model\ValueObject;

use App\Domain\Manga\Domain\Exception\InvalidExternalIdException;

readonly class ExternalId
{
    public function __construct(
        private string $value
    ) {
        if (empty($value)) {
            throw new InvalidExternalIdException('External ID cannot be empty');
        }
    }

    public function getValue(): string
    {
        return $this->value;
    }
}
