[PR #931] [CLOSED] Allow overriding getShortName() for discriminator map #8912

Closed
opened 2026-01-22 16:02:17 +01:00 by admin · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/doctrine/orm/pull/931
Author: @joshbuckley182
Created: 2/5/2014
Status: Closed

Base: masterHead: master


📝 Commits (1)

  • ca0337e Allow overriding getShortName() for discriminator map

📊 Changes

1 file changed (+1 additions, -1 deletions)

View changed files

📝 lib/Doctrine/ORM/Mapping/ClassMetadataFactory.php (+1 -1)

📄 Description

This will allow the keys for entries in a generated discriminator map to be customised. E.g. to include namespace

For example, if I had more than one entity with the same name, but used for different purposes, I could customise getShortName to include the namespace (or indeed just return the class name with no modifications), which would allow them both to work.


🔄 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/931 **Author:** [@joshbuckley182](https://github.com/joshbuckley182) **Created:** 2/5/2014 **Status:** ❌ Closed **Base:** `master` ← **Head:** `master` --- ### 📝 Commits (1) - [`ca0337e`](https://github.com/doctrine/orm/commit/ca0337e70b561df05c9c6f3db292180181e90ef4) Allow overriding getShortName() for discriminator map ### 📊 Changes **1 file changed** (+1 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `lib/Doctrine/ORM/Mapping/ClassMetadataFactory.php` (+1 -1) </details> ### 📄 Description This will allow the keys for entries in a generated discriminator map to be customised. E.g. to include namespace For example, if I had more than one entity with the same name, but used for different purposes, I could customise `getShortName` to include the namespace (or indeed just return the class name with no modifications), which would allow them both to work. --- <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 16:02:17 +01:00
admin closed this issue 2026-01-22 16:02:18 +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#8912