WordPress at a glance
function is not described

WP_REST_Server::get_route_options() public WP 4.4.0

Retrieves specified options for a route.

{} It's a method of the class: WP_REST_Server{}

No Hooks.

Return

Array/null. Data as an associative array if found, or null if not found.

Usage

$WP_REST_Server = new WP_REST_Server();
$WP_REST_Server->get_route_options( $route );
$route(string) (required)
Route pattern to fetch options for.

Changelog

Since 4.4.0 Introduced.

Code of WP_REST_Server::get_route_options() WP 5.5.2

<?php
public function get_route_options( $route ) {
	if ( ! isset( $this->route_options[ $route ] ) ) {
		return null;
	}

	return $this->route_options[ $route ];
}