private function addNamespaceFilter(ProjectDescriptorBuilder $builder, Filter $filterManager)
    {
        $filter = new LegacyNamespaceFilter($builder);

        // parse parameters
        foreach ($this->plugin->getParameters() as $param) {
            if ($param->getKey() == 'NamespacePrefix') {
                $filter->setNamespacePrefix($param->getValue());
            }
        }

        $filterManager->attach('phpDocumentor\Descriptor\ConstantDescriptor', $filter);
        $filterManager->attach('phpDocumentor\Descriptor\FunctionDescriptor', $filter);
        $filterManager->attach('phpDocumentor\Descriptor\InterfaceDescriptor', $filter);
        $filterManager->attach('phpDocumentor\Descriptor\TraitDescriptor', $filter);
        $filterManager->attach('phpDocumentor\Descriptor\PropertyDescriptor', $filter);
        $filterManager->attach('phpDocumentor\Descriptor\FileDescriptor', $filter);
        $filterManager->attach('phpDocumentor\Descriptor\ClassDescriptor', $filter);
    }