Yoast\WP\SEO\Schema_Aggregator\Application\Cache

Manager::get_cache_key │ private │ Yoast 1.0

Generate cache key for page.

Метод класса: Manager{}

Хуков нет.

Возвращает

string. Cache key.

Использование

// private - только в коде основоного (родительского) класса
$result = $this->get_cache_key( $post_type, $page, $per_page ): string;
$post_type(строка) (обязательный)
The post type that the cache is for.
$page(int) (обязательный)
Page number.
$per_page(int) (обязательный)
Items per page.

Код Manager::get_cache_key() Yoast 28.9

private function get_cache_key( string $post_type, int $page, int $per_page ): string {
	return \sprintf(
		'%s_page_%d_per_%d_type_%s_v%d',
		self::CACHE_PREFIX,
		$page,
		$per_page,
		$post_type,
		self::CACHE_VERSION,
	);
}