You are here

public function InMemoryConfig::__construct in Rocket.Chat 8

Same name and namespace in other branches
  1. 8.2 modules/rocket_chat_api/src/RocketChat/InMemoryConfig.php \Drupal\rocket_chat_api\RocketChat\InMemoryConfig::__construct()

InMemoryConfig constructor.

Parameters

\Drupal\rocket_chat_api\RocketChat\RocketChatConfigInterface $storedConfig: Stored Config Object (READ ONLY).

string $user: User name.

string $password: User Password.

File

modules/rocket_chat_api/src/RocketChat/InMemoryConfig.php, line 85

Class

InMemoryConfig
Class InMemoryConfig keeps the config in memory.

Namespace

Drupal\rocket_chat_api\RocketChat

Code

public function __construct(RocketChatConfigInterface &$storedConfig, &$user, &$password) {
  $this->superConfig = $storedConfig;
  $this->url = $storedConfig
    ->getElement('server', "http://localhost:3000");
  $this->user = $user;
  $this->password = $password;
  $this->uid = $storedConfig
    ->getElement('rocket_chat_uid');
  $this->utk = $storedConfig
    ->getElement('rocket_chat_uit');
}