public function processUrls($contact, $urls)
    {
        $get = function($url) {
            return $url->getId();
        };

        $delete = function($url) use ($contact) {
            return $contact->removeUrl($url);
        };

        $update = function($url, $matchedEntry) {
            return $this->updateUrl($url, $matchedEntry);
        };

        $add = function($url) use ($contact) {
            return $this->addUrl($contact, $url);
        };

        $entities = $contact->getUrls();

        $result = $this->processSubEntities(
            $entities,
            $urls,
            $get,
            $add,
            $update,
            $delete
        );

        $this->resetIndexOfSubentites($entities);

        // check main
        $this->setMainUrl($contact);

        return $result;
    }