Returns the child by id.

@param int $id
@return AbstractNode
@throws ChildNotFoundException
777882
public function getChild(int $id): AbstractNode
    {
        if ( ! isset($this->children[$id])) {
            throw new ChildNotFoundException("Child '$id' not found in this node.");
        }

        return $this->children[$id]['node'];
    }
1058385
public function getNode($id)
    {
        if (!isset($this->nodes[$id])) {
            throw new InvalidArgumentException(sprintf('There is no node with id "%s".', $id));
        }

        return $this->nodes[$id];
    }
568223
public function previousChild(int $id): AbstractNode
    {
        $child = $this->getchild($id);
        $next  = $this->children[$child->id()]['prev'];
        if (is_null($next)) {
            throw new ChildNotFoundException("Child '$id' previous not found in this node.");
        }

        return $this->getChild($next);
    }
433685
function (id) {
            var node;
            if (this.children && this.children.length) {
                for (var i = 0, ci; ci = this.children[i++];) {
                    if (node = getNodeById(ci, id)) {
                        return node;
                    }
                }
            }
        }
118678
public function get($id)
    {
        if (null === $id) {
            return;
        }

        if (isset($this->nodes[$id])) {
            return $this->nodes[$id];
        }

        $node = $this->repository->find($id);

        if (empty($node) or $node->isDeleted()) {
            return null;
        }

        return $node;
    }
1317814
private function doFind($id)
    {
        $id = $this->toIdentity($id);
        $entity = null === $id ? null : $this->em->find($this->class, $id);

        if (null === $entity) {
            throw EntityNotFoundException::createForId($this->class, $id);
        }

        return $entity;
    }
1369020
public function getChildById($id)
    {
        foreach ($this->children as $child) {
            if ($child->id === $id) {
                return $child;
            }

            $subChild = $child->getChildById($id);
            if ($subChild !== null) {
                return $subChild;
            }
        }

        return null;
    }
372591
public function getID($ID)
    {
        if($this->hasID($ID)) {
            return $this->offsetGet($this->safeOffset($ID));
        } else {
            throw new CollectionIDNotFoundException('ID "' . $ID . '" does not exist in collection');
        }
    }
807257
public function getOrFail($id)
    {
        if (!$this->storage->offsetExists($id)) {
            throw new ResourceNotFoundException("Model with id #$id not found.");
        }
        return $this->deserializeFromStorage($this->storage->offsetGet($id));
    }
30106
public function get($id)
    {
        if (!$this->has($id)) {
            throw new Exception\NotFoundException;
        }
        if (!$this->isReady($id)) {
            $this->instantiate($id);
        }
        return $this->instances[$id];
    }
322003
public function findById($id)
    {
        $entity = $this->getEntityManager()->getRepository($this->entityClass);
        return $entity->find($id);
    }
800301
public function findById(int $id)
    {
        $entity = null;

        for ($i = 0; $i < count($this->registries); $i++) {
            /** @var RegistryInterface $registry */
            $registry = $this->registries[ $i ];
            $entity = $registry->findByKey($id);

            if ($entity instanceof AbstractEntity) {
                $this->updateRegistries([$entity], $i - 1);
                break;
            }
        }

        return $entity;
    }
522160
public function nextChild(int $id): AbstractNode
    {
        $child = $this->getChild($id);
        $next  = $this->children[$child->id()]['next'];
        if (is_null($next)) {
            throw new ChildNotFoundException("Child '$id' next not found in this node.");
        }

        return $this->getChild($next);
    }
1299515
public function getById($id)
    {
        $node = $this->mainNode->getById($id);
        if (!$node) {
            return null;
        }

        return $node->getData();
    }
132408
public function getChild(string $id): NodeInterface
    {
        if (!$this->hasChild($id)) {
            throw ChildDoesNotExistException::create($this->getId(), $id);
        }

        return $this->_children[$id];
    }
929361
public function find($id)
    {
        if (!($object = $this->getDoctrineEntityRepository()->find($id))) {
            $this->throwException(sprintf('The resource \'%s\' was not found', $id), 'not-found');
        }

        return $object;
    }
1363415
static public function getAllIdChilds($id)
    {
        $map = self::getMapParentId();
        
        $childId = array();
        
        if (isset( $map[$id] ))
        {
            foreach ($map[$id] as $val)
            {
                $childId = array_merge($childId,self::getAllIdChilds($val));
            }
            unset($val);
            
            return $childId;
        }
        else
        {
            return array( $id );
        }              
    }