Multiple Post Types, Taxonomies, and Roles
The MasterPress API has a number of ways to access collections of object types within your WordPress site, that is – post types, taxonomies, and roles. Note that these methods are likely to be rarely used in theme development, but they could be very useful in building custom dashboard metaboxes or plugin screens.
Retrieving Post Types
Example 1: Retrieving all post types
Example 2: Retrieving post types for a specific taxonomy
To access a collection of all taxonomies in your WordPress site you can use the WOOF::taxonomies method:
Example 3: Retrieving all taxonomies
Note that this method uses WordPress’ get_taxonomies method to find taxonomies, so you can also specify an arguments string or array as in the examples on the get_taxonomies manual page.
Example 4: Retrieving taxonomies for a specific post type
Retrieving User Roles
To access a collection of all user roles in your WordPress site, you can use the method WOOF::roles method: