public function isExists() { $params = array('TYPE_ID' => $this->typeID, 'ENTITY_TYPE_ID' => $this->getEntityTypeID(), 'USER_ID' => $this->getUserID()); if ($this->typeID === DuplicateIndexType::PERSON) { return DuplicatePersonCriterion::checkIndex($params); } elseif ($this->typeID === DuplicateIndexType::ORGANIZATION) { return DuplicateOrganizationCriterion::checkIndex($params); } elseif ($this->typeID === DuplicateIndexType::COMMUNICATION_PHONE || $this->typeID === DuplicateIndexType::COMMUNICATION_EMAIL) { return DuplicateCommunicationCriterion::checkIndex($params); } else { throw new Main\NotSupportedException("Criterion type(s): '" . DuplicateIndexType::resolveName($this->typeID) . "' is not supported in current context"); } }