public function hasProperty($id, $name, $directAccess = false)
    {
        if (!$directAccess) {
            $id = $this->validateAndResolveId($id);
        }

        return isset($this->items[$id][$name]) || array_key_exists($name, $this->items[$id]);
    }