You are here

public function BaseApiAbstract::__construct in TMGMT Translator Smartling 8.4

Same name and namespace in other branches
  1. 8.2 api-sdk-php/src/BaseApiAbstract.php \Smartling\BaseApiAbstract::__construct()
  2. 8.2 vendor/smartling/api-sdk-php/src/BaseApiAbstract.php \Smartling\BaseApiAbstract::__construct()
  3. 8.3 vendor/smartling/api-sdk-php/src/BaseApiAbstract.php \Smartling\BaseApiAbstract::__construct()

BaseApiAbstract constructor.

Parameters

string $projectId:

ClientInterface $client:

LoggerInterface $logger:

string|null $service_url:

3 calls to BaseApiAbstract::__construct()
AuditLogApi::__construct in vendor/smartling/api-sdk-php/src/AuditLog/AuditLogApi.php
BaseApiAbstract constructor.
AuthTokenProvider::__construct in vendor/smartling/api-sdk-php/src/AuthApi/AuthTokenProvider.php
AuthTokenProvider constructor.
ProgressTrackerApi::__construct in vendor/smartling/api-sdk-php/src/ProgressTracker/ProgressTrackerApi.php
BaseApiAbstract constructor.
3 methods override BaseApiAbstract::__construct()
AuditLogApi::__construct in vendor/smartling/api-sdk-php/src/AuditLog/AuditLogApi.php
BaseApiAbstract constructor.
AuthTokenProvider::__construct in vendor/smartling/api-sdk-php/src/AuthApi/AuthTokenProvider.php
AuthTokenProvider constructor.
ProgressTrackerApi::__construct in vendor/smartling/api-sdk-php/src/ProgressTracker/ProgressTrackerApi.php
BaseApiAbstract constructor.

File

vendor/smartling/api-sdk-php/src/BaseApiAbstract.php, line 218

Class

BaseApiAbstract
Class BaseApiAbstract

Namespace

Smartling

Code

public function __construct($projectId, ClientInterface $client, $logger = null, $service_url = null) {
  $this
    ->setProjectId($projectId);
  $this
    ->setHttpClient($client);
  if (is_null($logger)) {
    $logger = new DevNullLogger();
  }
  $this
    ->setLogger($logger);
  $this
    ->setBaseUrl(rtrim($service_url, '/') . '/' . $projectId);
}