private function processResourceName(\ArrayIterator $iterator, ResourceRecord $resourceRecord): void
    {
        if ($this->isResourceName($iterator)) {
            $this->previousName = $iterator->current();
            $iterator->next();
        }

        $resourceRecord->setName($this->previousName);
    }