Is it possible to make use of annotations in the annotated class? Drupal using Doctrine
For updating Views in Drupal core to use plugins for aggregation functionality, i could replicate
- drupal plugin class see its own ID
- doctrine class read its own annotations
- doctrine can a class see its annotations
Seems like a class knows its own classname, even if the method is in a base class i think you can access the current class, and then from their you can just load all of doctrine and grab the annotation out of its data store.
Not sure if any Drupal-specific stuff helps with that?
But some notes on general approach, haven’t found anyone doing simply what i’m thinking of though.
https://stackoverflow.com/questions/20894705/how-to-check-if-a-class-is-a-doctrine-entity/20907212