[PR #533] [CLOSED] added DiscriminatorMapEntry mapping #8339

Closed
opened 2026-01-22 15:59:28 +01:00 by admin · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/doctrine/orm/pull/533
Author: @Padam87
Created: 12/11/2012
Status: Closed

Base: masterHead: master


📝 Commits (5)

  • 19917e8 added DiscriminatorMapEntryMapping
  • 5aefa52 fixed XmlDriver for DiscriminatorMapEntry
  • b148b0e DiscriminatorMapEntry - add sub and parent classes
  • e250c7f DiscriminatorMapEntry - check ig the map has actually been modified
  • 914d5b3 DiscriminatorMapEntry - moved block to after the parent classes has been set

📊 Changes

5 files changed (+60 additions, -2 deletions)

View changed files

📝 lib/Doctrine/ORM/Mapping/ClassMetadataFactory.php (+13 -0)
lib/Doctrine/ORM/Mapping/DiscriminatorMapEntry.php (+30 -0)
📝 lib/Doctrine/ORM/Mapping/Driver/AnnotationDriver.php (+6 -1)
📝 lib/Doctrine/ORM/Mapping/Driver/XmlDriver.php (+6 -0)
📝 lib/Doctrine/ORM/Mapping/Driver/YamlDriver.php (+5 -1)

📄 Description

In Symfony2, if the main entity is in a separate bundle, from a vendor, changing the DiscriminatorMap is not a good idea.
Thats why we should be able to add entries to the map.

Mapping:

yaml:

discriminatorMapEntry: keyHere

annotation:

@DiscriminatorMapEntry("keyHere")

xml:


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/doctrine/orm/pull/533 **Author:** [@Padam87](https://github.com/Padam87) **Created:** 12/11/2012 **Status:** ❌ Closed **Base:** `master` ← **Head:** `master` --- ### 📝 Commits (5) - [`19917e8`](https://github.com/doctrine/orm/commit/19917e8d672129cefdfe39881e93bf5001a3a60f) added DiscriminatorMapEntryMapping - [`5aefa52`](https://github.com/doctrine/orm/commit/5aefa5250e3c675b922c5b2621a1542201e7dfb0) fixed XmlDriver for DiscriminatorMapEntry - [`b148b0e`](https://github.com/doctrine/orm/commit/b148b0e06a1a2845729c05558022bd34029c6f0b) DiscriminatorMapEntry - add sub and parent classes - [`e250c7f`](https://github.com/doctrine/orm/commit/e250c7fd30215e5731c07f3ab9cb14713b03325f) DiscriminatorMapEntry - check ig the map has actually been modified - [`914d5b3`](https://github.com/doctrine/orm/commit/914d5b37d56050dbfb84b36978182acd24a16241) DiscriminatorMapEntry - moved block to after the parent classes has been set ### 📊 Changes **5 files changed** (+60 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `lib/Doctrine/ORM/Mapping/ClassMetadataFactory.php` (+13 -0) ➕ `lib/Doctrine/ORM/Mapping/DiscriminatorMapEntry.php` (+30 -0) 📝 `lib/Doctrine/ORM/Mapping/Driver/AnnotationDriver.php` (+6 -1) 📝 `lib/Doctrine/ORM/Mapping/Driver/XmlDriver.php` (+6 -0) 📝 `lib/Doctrine/ORM/Mapping/Driver/YamlDriver.php` (+5 -1) </details> ### 📄 Description In Symfony2, if the main entity is in a separate bundle, from a vendor, changing the DiscriminatorMap is not a good idea. Thats why we should be able to add entries to the map. Mapping: yaml: discriminatorMapEntry: keyHere annotation: @DiscriminatorMapEntry("keyHere") xml: <discriminator-map-entry name="keyHere" /> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
admin added the pull-request label 2026-01-22 15:59:28 +01:00
admin closed this issue 2026-01-22 15:59:28 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#8339