Gets an element based on its id
@param string $id The id of the element to return
@return Array An element array or false
962336
public function &getElementById( $id )
	{
		$id = urldecode( $id );

		$fragment = parse_url( $id, PHP_URL_FRAGMENT );
		$fragment = $fragment ? $fragment : $id;

		if ( ! isset( $this->elementIndex[ $fragment ] ) )
		{
			$false = false;
			return $false;
		}
		$element = &$this->elementIndex[ $fragment ];
		return $element;
	}
425147
public function getModuleById($id)
    {
        $modules = \JModuleHelper::getModules(null);

        $total = count($modules);

        for ($i = 0; $i < $total; $i++)
        {
            if ($modules[$i]->id == $id)
            {
                return $modules[$i];
            }
        }

        return null;
    }
952750
public function getById($id)
    {
        $modelResult = $this->getRequest()->request(
            'GET',
            $this->getRequestUrl(sprintf('models/%s', $id))
        );

        return $this->getModelFromResult($modelResult);
    }
1306946
public function getById($id)
    {
        if (isset($this->idList[$id])) {
            return $this->idList[$id];
        }

        return null;
    }
645411
public function getElementById($id)
    {
        // start with document
        $stack = array($this);

        while (!empty($stack)) {
            $elem = array_pop($stack);
            // check current node
            if ($elem->getAttribute('id') === $id) {
                return $elem;
            }
            // add children to stack (tree order traversal)
            if ($elem instanceof SVGNodeContainer) {
                for ($i = $elem->countChildren() - 1; $i >= 0; --$i) {
                    array_push($stack, $elem->getChild($i));
                }
            }
        }

        return null;
    }
866650
public function getPage($id)
    {
        $found_page = null;

        foreach ($this->pages as $page) {
            if ($page->id == $id) {
                $found_page = $page;
                break;
            }
        }

        return $found_page;
    }
996991
public function getRoute($id)
    {
        return isset($this->routes[$id]) ? $this->routes[$id] : false;
    }
382492
public function get_item($id)
	{
		// Element empty!
		if (count($this->_items) === 0)
			return FALSE;

		if (array_key_exists($id, $this->_items))
		{ // By ID
			return $this->_items[$id];
		} else
		{ // By route
			$path = $this->get_tree_index(Route::get($id));

			if($path != false)
			{
				$levels = count($path);

				$item = $this->_items[$path[0]];

				if($levels > 1)
				{
					for($i=1; $i<$levels; $i++)
					{
						$item = $item->siblings[$path[$i]];
					}
				}
				return $item;
			}
		}
		return FALSE;
	}
966283
public function getElementById($id)
    {
        foreach ($this->getRecursiveIterator() as $element) {
            if ($id == $element->getId()) {
                return $element;
            }
        }
        return null;
    }
255096
public function getById($id)
    {
        $query = function () use ($id) {
            return $this->model
                ->with($this->requiredRelationships)
                ->find($id);
        };

        return $this->doQuery($query);
    }
1124850
public function getById($id)
    {
        $list = $this->getByCriteria($id, $this->getUniqueId());
        return reset($list);
    }
796029
public static function get($id){
		if( isset(self::$instances[$id]) ){
			return self::$instances[$id];
		}
		return null;
	}
805483
public function get($id)
    {
        if (!is_array($id)) {
            $index = $this->getIndex();
            $id = $this->db->escape_string($id);
            return $this->build($this->db->select('SELECT * FROM `' . $this->table_name . '` WHERE `' . $index . '` = ? ',
                array($id), $this->getCacheId($id)));
        }
        if (is_array($id)) {
            $fieldsValue = $id;
            $fields = $this->getFields();
            $sql = '';
            $args = array();
            foreach ($fields as $field) {
                if (isset($fieldsValue[$field])) {
                    $args[$field] = $fieldsValue[$field];
                    $sql .= '`' . $field . '` = :' . $field . ' AND ';
                }
            }
            if (!empty($sql)) {
                $sql = substr($sql, 0, -5);
                return $this->build($this->db->select('SELECT * FROM `' . $this->table_name . '` WHERE ' . $sql, $args, $this->getCacheId($id)));
            }
        }
        return $this->build(array());
    }
113915
public function findById($id)
    {
        $id = $this->getRepository()->idToMongo($id);
        return $this->mergeCriteria(array('_id' => $id));
    }
895002
public function get($id)
    {
        foreach ($this->children as $child) {
            if ($id === $child->getId()) {
                return $child;
            }
        }
    }
578876
public function find(string $id)
    {
        $element = $this->first(function ($element) use ($id) {
            return $element->id() === $id;
        });

        if (!$element) {
            $this->notFound($id);
        }

        return $element;
    }
378743
public function get($id)
    {
        if (isset($this->values[$id])) {
            return $this->values[$id];
        }

        $callback = $this->getCallback($id);
        $value = call_user_func($callback);

        return $this->values[$id] = $value;
    }