public function convert(\DOMElement $parent, InterfaceDescriptor $interface)
    {
        $child = new \DOMElement('interface');
        $parent->appendChild($child);

        /** @var InterfaceDescriptor $parentInterface */
        foreach ($interface->getParent() as $parentInterface) {
            $parentFqcn = is_string($parentInterface) === false
                ? $parentInterface->getFullyQualifiedStructuralElementName()
                : $parentInterface;
            $child->appendChild(new \DOMElement('extends', $parentFqcn));
        }

        $namespace = $interface->getNamespace()->getFullyQualifiedStructuralElementName();
        $child->setAttribute('namespace', ltrim($namespace, '\\'));
        $child->setAttribute('line', $interface->getLine());

        $child->appendChild(new \DOMElement('name', $interface->getName()));
        $child->appendChild(new \DOMElement('full_name', $interface->getFullyQualifiedStructuralElementName()));

        $this->docBlockConverter->convert($child, $interface);

        foreach ($interface->getConstants() as $constant) {
            $this->constantConverter->convert($child, $constant);
        }

        foreach ($interface->getMethods() as $method) {
            $this->methodConverter->convert($child, $method);
        }

        return $child;
    }