private function entryExists(ConfigurationEntryDefinition $entry) { return (bool) $this->em->getRepository(ConfigurationEntry::clazz())->findOneBy(array('name' => $entry->getName())); }
/** * @param ConfigurationEntryDefinition $def * * @return ConfigurationEntry */ public static function createFromDefinition(ConfigurationEntryDefinition $def) { $me = new self($def->getName()); $me->setReadableName($def->getReadableName()); $me->setValue($def->getValue()); $me->setServerHandlerConfig($def->getServerHandlerConfig()); $me->setClientHandlerConfig($def->getClientHandlerConfig()); $me->setExposed($def->isExposed()); $me->setCategory($def->getCategory()); return $me; }