abstract class Post_Screens extends Screens

A manager for screens that belong to a post type.

Properties

static protected int $screen_hook_priority from  Screens

Methods

static 
construct_screen()

The primary entry function for running code globally in the admin area. This code will run with regular Module constructions.

from  Screens
static 
current_screen(WP_Screen $current_screen)

The primary entry function for running code locally in the screen. This code will run in the 'current_screen' WordPress hook.

from  Screens
static array[]
get_valid_screens()

The required abstract inherited function for returning screen actions.

static bool
is_current_screen()

Iterates through the current screen 'base', 'id', and 'action' sequentially through the valid screens of this class and returns TRUE if they match, otherwise FALSE.

from  Screens
static false|callable
get_current_screen_callback()

Returns the callback function associated with the current screen in this class. Otherwise, if not on a valid screen, returns FALSE.

from  Screens
static 
construct()

The primary entry point for the Admin Module to call when registering this Screen.

from  Screens
static 
_current_screen(WP_Screen $current_screen)

The WordPress hook 'current_screen' which should be used to construct the screen module since that is when the data is available.

from  Screens
static 
post_type()

Get the post type of the posts that this screen is associated with.

static 
view_posts(WP_Screen $current_screen)

The function which hooks when viewing multiple Posts of the static post type.

static 
view_post(WP_Screen $current_screen)

The function which hooks when viewing a single Post of the static post type.

static 
add_post(WP_Screen $current_screen)

The function that hooks when adding a new Post of the static post type.

Details

in Screens at line 31
abstract static construct_screen()

The primary entry function for running code globally in the admin area. This code will run with regular Module constructions.

in Screens at line 39
abstract static current_screen(WP_Screen $current_screen)

The primary entry function for running code locally in the screen. This code will run in the 'current_screen' WordPress hook.

This function will be called when any page from the valid screens is matched.

Parameters

WP_Screen $current_screen

The current Screen being viewed.

at line 52
final static array[] get_valid_screens()

The required abstract inherited function for returning screen actions.

Return Value

array[]

The IDs for which the screen matches.

in Screens at line 73
final static bool is_current_screen()

Iterates through the current screen 'base', 'id', and 'action' sequentially through the valid screens of this class and returns TRUE if they match, otherwise FALSE.

Return Value

bool

Whether the current screen matches one of the valid screens of this class.

in Screens at line 107
final static false|callable get_current_screen_callback()

Returns the callback function associated with the current screen in this class. Otherwise, if not on a valid screen, returns FALSE.

Return Value

false|callable

The callable function associated with the static class instance or FALSE.

in Screens at line 125
static construct()

The primary entry point for the Admin Module to call when registering this Screen.

in Screens at line 133
final static _current_screen(WP_Screen $current_screen)

The WordPress hook 'current_screen' which should be used to construct the screen module since that is when the data is available.

Parameters

WP_Screen $current_screen

at line 30
abstract static post_type()

Get the post type of the posts that this screen is associated with.

at line 35
abstract static view_posts(WP_Screen $current_screen)

The function which hooks when viewing multiple Posts of the static post type.

Parameters

WP_Screen $current_screen

at line 40
abstract static view_post(WP_Screen $current_screen)

The function which hooks when viewing a single Post of the static post type.

Parameters

WP_Screen $current_screen

at line 45
abstract static add_post(WP_Screen $current_screen)

The function that hooks when adding a new Post of the static post type.

Parameters

WP_Screen $current_screen