-
Notifications
You must be signed in to change notification settings - Fork 239
List supported entities, their actions and VP tags #804
Description
So far, we didn't really need programmatic access to a list of entities and what actions and VP tags they support. The best we had were PhpDoc comments like this:
/**
* Post changes.
*
* VP tags:
*
* VP-Action: post/(create|edit|delete|trash|untrash|draft|publish)/VPID
* VP-Post-Title: Hello world
* VP-Post-Type: (post|page)
* VP-Post-UpdatedProperties: post_title,post_content,post_status
*/
class PostChangeInfo extends EntityChangeInfo {
...
}However, since the tags can be searched for since #586, we need to at least document what the valid search keywords are, and better, provide auto-completion or some sort of GUI for that in the future. Maintaining this manually would be a pain so the goal of this ticket is to create a mechanism to get the list of all the possible entities and their actions / tags programmatically.
Note: We might be moving away from ChangeInfo and deep object hierarchies to something simpler in v4 or v5 (UPDATE: we now have a ticket for this, #1034) so this ticket might be revisited later. However, the idea stays.