public function getId(): string {
        $ids = $this->getIds();
        if (count($ids) === 0) {
            throw new NoAcdhId();
        }
        $acdhId = null;
        foreach ($ids as $id) {
            $inIdNmsp     = strpos($id, RC::idNmsp()) === 0;
            $inVocabsNmsp = strpos($id, RC::vocabsNmsp()) === 0;
            if ($inIdNmsp || $inVocabsNmsp) {
                if ($acdhId !== null) {
                    throw new ManyAcdhIds();
                }
                $acdhId = $id;
            }
        }
        if ($acdhId === null) {
            throw new NoAcdhId();
        }
        return $acdhId;
    }