Yoast\WP\SEO\AI\Content_Planner\Infrastructure\Endpoints

Get_Outline_Endpoint{}Yoast 1.0└─ Content_Planner_Endpoint_Interface

Represents the content planner endpoint to retrieve the outline.

Хуков нет.

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

$Get_Outline_Endpoint = new Get_Outline_Endpoint();
// use class methods

Методы

  1. public get_name()
  2. public get_namespace()
  3. public get_route()
  4. public get_url()

Код Get_Outline_Endpoint{} Yoast 27.7

class Get_Outline_Endpoint implements Content_Planner_Endpoint_Interface {

	/**
	 * Gets the name.
	 *
	 * @return string
	 */
	public function get_name(): string {
		return 'getOutline';
	}

	/**
	 * Gets the namespace.
	 *
	 * @return string
	 */
	public function get_namespace(): string {
		return Get_Outline_Route::ROUTE_NAMESPACE;
	}

	/**
	 * Gets the route.
	 *
	 * @return string
	 */
	public function get_route(): string {
		return Get_Outline_Route::ROUTE_PREFIX;
	}

	/**
	 * Gets the URL.
	 *
	 * @return string
	 */
	public function get_url(): string {
		return \rest_url( $this->get_namespace() . $this->get_route() );
	}
}