protected function addEntityMapping(
        ContainerBuilder $container,
        $entityManagerName,
        $entityNamespace,
        $entityMappingFilePath,
        $enable = true
    ) : self {
        $entityMapping = $this->resolveEntityMapping(
            $container,
            $entityManagerName,
            $entityNamespace,
            $entityMappingFilePath,
            $enable
        );

        if ($entityMapping instanceof EntityMapping) {
            $this->registerLocatorConfigurator($container);
            $this->registerLocator($container, $entityMapping);
            $this->registerDriver($container, $entityMapping);
            $this->addDriverInDriverChain($container, $entityMapping);
            $this->addAliases($container, $entityMapping);
        }

        return $this;
    }