You are here

private function CmisRepositoryController::initBrowser in CMIS API 8

Same name and namespace in other branches
  1. 8.2 src/Controller/CmisRepositoryController.php \Drupal\cmis\Controller\CmisRepositoryController::initBrowser()
  2. 3.0.x src/Controller/CmisRepositoryController.php \Drupal\cmis\Controller\CmisRepositoryController::initBrowser()

Init browser.

Parameters

string $config:

string $folder_id:

Return value

array

3 calls to CmisRepositoryController::initBrowser()
CmisRepositoryController::browse in src/Controller/CmisRepositoryController.php
Browse.
CmisRepositoryController::getProperties in src/Controller/CmisRepositoryController.php
Get prperties
CmisRepositoryController::__construct in src/Controller/CmisRepositoryController.php
Construct.

File

src/Controller/CmisRepositoryController.php, line 212

Class

CmisRepositoryController
Class CmisRepositoryController.

Namespace

Drupal\cmis\Controller

Code

private function initBrowser($config, $folder_id) {
  if (!empty($config)) {
    $browser = new CmisBrowser($config, $folder_id);
    if ($browser
      ->getConnection()) {
      $this->browser = $browser;
    }
    else {
      return $this
        ->connectionError($config);
    }
  }
  else {
    return $this
      ->configureError();
  }
}