Bridge/Doctrine/ORM/Listener/LoadMetadataListener.php
private function configureIdentityMapping(LoadClassMetadataEventArgs $eventArgs)
    {
        /** @var ClassMetadata $metadata */
        $metadata = $eventArgs->getClassMetadata();
        $class = $metadata->getName();

        // Check class
        if (!is_subclass_of($class, IdentityInterface::class)) {
            return;
        }

        // Don't add twice
        if (in_array($class, $this->identityClassCache)) {
            return;
        }

        // Add mappings
        $this->addMappings($metadata, $this->getIdentityMappings());

        // Cache class
        $this->identityClassCache[] = $class;
    }
private function configureIdentityMapping(LoadClassMetadataEventArgs $eventArgs)
    {
        /** @var ClassMetadata $metadata */
        $metadata = $eventArgs->getClassMetadata();
        $class = $metadata->getName();

        // Check class
        if (!is_subclass_of($class, IdentityInterface::class)) {
            return;
        }

        // Don't add twice
        if (in_array($class, $this->identityClassCache)) {
            return;
        }

        // Add mappings
        $this->addMappings($metadata, $this->getIdentityMappings());

        // Cache class
        $this->identityClassCache[] = $class;
    }
Configures the identity mapping.

@param LoadClassMetadataEventArgs $eventArgs