public function getData($offset)
    {
        $this->parserPosition = null;
        $this->parserLevel    = 0;
        $data        = "";
        $parser      = @\xml_parser_create();
        $filePointer = $this->getIndex()->getFile()->getFilePointer();

        if (! \is_resource($parser)) {
            $error = \error_get_last();
            throw new ReadDataIndexException(
                "Could not create a xml parser: $error[message]"
            );

        }

        \xml_set_element_handler(
            $parser,
            array($this, "onStartElement"),
            array($this, "onEndElement")
        );

        \fseek($filePointer, $offset);
        while (\is_null($this->parserPosition)
                    && $chunk = \fread($filePointer, $this->getIndex()->getFile()->getBlockSize())
        ) {
            $data .= $chunk;
            \xml_parse($parser, $chunk);

        }

        \xml_parser_free($parser);

        if (\is_null($this->parserPosition)) {
            throw new ReadDataIndexException("Did not read any data");

        }
        return \substr($data, 0, $this->parserPosition);
    }