private function parseDescription($filename, $entityClass)
    {
        $parser = new XmlParser();

        $parser->open($filename);

        /** @var EntityStructure $definition */
        $definition = $parser->parse([
            'onBeforeEntity'   => [$this, 'prepareEntity'],
            'onAfterEntity'    => [$this, 'handleEntity'],
            'onAfterField'     => [$this, 'handleField'],
            'onBeforeOption'   => [$this, 'prepareOption'],
            'onAfterOption'    => [$this, 'handleOption'],
            'onBeforeFieldset' => [$this, 'prepareFieldset'],
            'onAfterFieldset'  => [$this, 'handleFieldset'],
        ], $this->locator);

        return $definition;
    }