| Server IP : 195.130.67.5 / Your IP : 216.73.217.127 Web Server : Microsoft-IIS/10.0 System : Windows NT WEBSERVER1 10.0 build 17763 (Windows Server 2016) i586 User : IUSR ( 0) PHP Version : 7.4.19 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : C:/inetpub/wwwroot/icd/mscinformatics2022/wp-content/plugins/polylang/src/modules/REST/ |
Upload File : |
<?php
/**
* @package Polylang
*/
namespace WP_Syntex\Polylang\REST;
use PLL_Model;
defined( 'ABSPATH' ) || exit;
/**
* Sets all Polylang REST controllers up.
*
* @since 3.7
*/
class API {
/**
* REST languages.
*
* @var V1\Languages|null
*/
public $languages;
/**
* REST settings.
*
* @var V1\Settings|null
*/
public $settings;
/**
* @var PLL_Model
*/
private $model;
/**
* Constructor.
*
* @since 3.7
*
* @param PLL_Model $model Polylang's model.
*/
public function __construct( PLL_Model $model ) {
$this->model = $model;
}
/**
* Adds hooks and registers endpoints.
*
* @since 3.7
*
* @return void
*/
public function init(): void {
$this->languages = new V1\Languages( $this->model );
$this->languages->register_routes();
$this->settings = new V1\Settings( $this->model );
$this->settings->register_routes();
}
}