Check if an object id is registered in the registry
@param $oid The object id to check
@return Boolean whether the object id is registered or not
499382
protected function isRegistered(ObjectId $oid) {
    $registry = $this->getLocalSessionValue(self::REGISTRY_VAR);
    return in_array($oid->__toString(), $registry);
  }
1034518
public function hasDocument(string $id): bool
    {
        if (isset($this->documents[$id])) {
            return true;
        }

        $path = $this->getDocumentPath($id);

        if ($this->filesystem->has($path)) {
            $info = $this->filesystem->getMetadata($path);

            return $info['type'] === 'file';
        }

        return false;
    }
1347165
public function realWalk1d($oid) {

        $arrayData = $this->realWalk($oid);

        $result = array();

        foreach ($arrayData as $_oid => $value) {

            $oidPrefix = substr($_oid, 0, strrpos($_oid, '.'));

            if (!isset($result[$oidPrefix])) {
                $result[$oidPrefix] = Array();
            }
            $aIndexOid = str_replace($oidPrefix . ".", "", $_oid);
            $result[$oidPrefix][$aIndexOid] = $this->parseSnmpValue($value);
        }

        return $result;
    }
651319
public function has($id)
    {
        // second argument
        $withAutowiring = func_num_args() > 1 ? (bool) func_get_arg(1) :
            $this->autowiring;

        // return FALSE if $id not a string
        return is_string($id) && (
            // found in definitions ?
            isset($this->services[$id])  ||

            // Or in definition providers ?
            $this->hasInProvider($id) ||

            // Or with id autowired ?
            $this->autoWiringId($id, $withAutowiring)
        ) ? true : false;
    }
53129
private static function getAnchorTypeByOid($oid)
    {
        $anchorTypesMap = self::getAnchorTypesMap();
        return isset($anchorTypesMap[$oid]) ? $anchorTypesMap[$oid] : 'Unknown';
    }
633020
protected function getCopyOID(ObjectId $origOID) {
    $registry = $this->getLocalSessionValue(self::OBJECT_MAP_VAR);

    // check if the oid exists in the registry
    $oidStr = $origOID->__toString();
    if (!isset($registry[$oidStr])) {
      $logger = $this->getLogger();
      if ($logger->isDebugEnabled()) {
        $logger->debug("Copy of ".$oidStr." not found.");
      }
      return null;
    }

    $copyOID = ObjectId::parse($registry[$oidStr]);
    return $copyOID;
  }
105410
private function getObjInfo($objectId)
    {
        //映射不存在 ,则先创建
        if(empty($this->m_objectInfoMap)){
            $configData=$this->m_config->getConfigValues($this->m_configSection);
            $this->m_objectInfoMap=$this->loadObjMap($configData);
        }

        //对象信息
        if(array_key_exists($objectId, $this->m_objectInfoMap)){
            return $this->m_objectInfoMap[$objectId];
        }
        return null;
    }
1045075
final protected function retrieveObjectIdentityPrimaryKey(ObjectIdentityInterface $oid)
    {
        return $this->connection->executeQuery($this->getSelectObjectIdentityIdSql($oid))->fetchColumn();
    }
43860
public function isRegistered($identifier)
    {
        if (false === parent::isRegistered($identifier)) {
            $entity = $this->getContentById($identifier);

            if (!empty($entity)) {
                return true;
            }
        } else {

            return true;
        }

        return false;
    }
566451
private function createObjectIdentity(ObjectIdentityInterface $oid)
    {
        $classId = $this->createOrRetrieveClassId($oid->getType());

        $this->connection->executeQuery($this->getInsertObjectIdentitySql($oid->getIdentifier(), $classId, true));
    }
611186
public function isRegisteredValueObject($object)
    {
        if (!is_string($object)) {
            $object = get_class($object);
        }

        return array_key_exists($object, $this->valueClasses);
    }
167614
public function hasChildWithValidPolicy(string $oid): bool
    {
        foreach ($this->_children as $node) {
            if ($node->validPolicy() == $oid) {
                return true;
            }
        }
        return false;
    }
1170401
private function isAutoWirable($id): bool
    {
        if (is_string($id) && class_exists($id)) {

            if (count($this->interfaces) > 0) {

                return (bool) array_intersect($this->interfaces, class_implements($id));

            }

            return true;

        }

        return false;
    }
549517
public static function getCustomParams($oid=null, $folder=null, $element=null)
	{
		$result = self::oneByPlugin($oid, $folder, $element);

		return new Registry($result->get('params'));
	}
948303
public function isRegistered($identifier)
    {
        if (!parent::isRegistered($identifier)) {

            $this->load();

            return parent::isRegistered($identifier);
        }

        return true;
    }
1337844
public function getid($openid)
    {
        if (!$openid) {
            $this->setError('参数错误,缺少Openid');

            return false;
        }

        $queryStr = ['openid' => $openid];

        $res = $this->_post('getid', $queryStr);

        return $res;
    }
83976
public function has($id)
    {
        if (array_key_exists($id, $this->entityClassNameCache)) {
            return false !== $this->entityClassNameCache[$id];
        }

        $objectManagerAutoDetector = $this->getObjectManagerAutoDetector();
        if (!$objectManagerAutoDetector->hasObjectManagerNameByClassName($id)) {
            $this->entityClassNameCache[$id] = false;
            return false;
        }
        $objectManagerName = $objectManagerAutoDetector->getObjectManagerNameByClassName($id);

        $doctrineOrmModuleConfig = $this->getDoctrineOrmModuleConfig();
        if (!$doctrineOrmModuleConfig->hasNamespacesByObjectManager($objectManagerName)) {
            $this->entityClassNameCache[$id] = false;
            return false;
        }

        $namespacesIndex = $doctrineOrmModuleConfig->getNamespacesIndexByObjectManagerName($objectManagerName);

        if (false === $this->hasEntityPostfixByInterfaceName($id)) {
            $this->entityClassNameCache[$id] = false;
            return false;
        }
        $entityPostfix = $this->getEntityPostfixByInterfaceName($id);

        $entityClassName = $this->resolveEntityClassName($entityPostfix, $namespacesIndex, $id);

        $this->entityClassNameCache[$id] = $entityClassName;

        return false !== $this->entityClassNameCache[$id];
    }