wp-includes/abilities-api/class-wp-ability.php:21Encapsulates the properties and methods related to a specific ability in the registry.
Every hook that fires from inside WP_Ability, in the order it appears in the class, grouped by the method that fires it.
$default_annotationsarray<string,protected static$namestringprotected$labelstringprotected$descriptionstringprotected$categorystringprotected$input_schemaarray<string,protected$output_schemaarray<string,protected$execute_callbackcallable(protected$permission_callbackcallable(protected$metaarray<string,protectedclass WP_Ability { /** * The default value for the `show_in_rest` meta. * * @since 6.9.0 * @var bool */ protected const DEFAULT_SHOW_IN_REST = false; /** * The default ability annotations. * They are not guaranteed to provide a faithful description of ability behavior. * * @since 6.9.0 * @var array<string, bool|null> */ protected static $default_annotations = array( // If true, the ability does not modify its environment. 'readonly' => null, /* * If true, the ability may perform destructive updates to its environment. * If false, the ability performs only additive updates. */ 'destructive' => null, /* * If true, calling the ability repeatedly with the same arguments will have no additional effect * on its environment. */ 'idempotent' => null, ); /** * The name of the ability, with its namespace. * Example: `my-plugin/my-ability`. * * @since 6.9.0 * @var string */ protected $name; /** * The human-readable ability label. * * @since 6.9.0 * @var string */ protected $label; /** * The detailed ability description. * * @since 6.9.0 * @var string */ protected $description; /** * The ability category. * * @since 6.9.0 * @var string */ protected $category; /** * The optional ability input schema. * * @since 6.9.0 * @var array<string, mixed> */ protected $input_schema = array(); /** * The optional ability output schema. * * @since 6.9.0 * @var array<string, mixed> */ protected $output_schema = array();Introduced in 6.9.0. Unchanged from 6.9.7 through 7.1.0.
Signature, return type and hooks compared across 3 parsed releases.
src/wp-includes/abilities-api/class-wp-ability.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.