function RestExampleClientController::__construct

Same name in other branches
  1. 3.x modules/rest_example/src/Controller/RestExampleClientController.php \Drupal\rest_example\Controller\RestExampleClientController::__construct()

Constructs a new \Drupal\rest_example\Controller\RestExampleClientController object.

Parameters

\Drupal\rest_example\RestExampleClientCalls $rest_client: The service to make REST calls.

File

modules/rest_example/src/Controller/RestExampleClientController.php, line 43

Class

RestExampleClientController
Controller class for the REST Example routes.

Namespace

Drupal\rest_example\Controller

Code

public function __construct(ConfigFactoryInterface $config_factory, RestExampleClientCalls $rest_client) {
    $this->configFactory = $config_factory;
    $this->restClient = $rest_client;
}