Thruway\Peer\Client::setAuthId PHP Method

setAuthId() public method

Set authenticate ID
public setAuthId ( string $authId )
$authId string
    public function setAuthId($authId)
    {
        $this->authId = $authId;
    }

Usage Example

Example #1
0
 /**
  * Constructor
  *
  * @param array $options
  * @param \React\EventLoop\LoopInterface $loop
  * @throws \Exception
  */
 public function __construct(array $options, LoopInterface $loop = null)
 {
     $this->options = $options;
     $this->client = new Client($options['realm'], $loop);
     $url = isset($options['url']) ? $options['url'] : null;
     $pawlTransport = new PawlTransportProvider($url);
     $this->client->addTransportProvider($pawlTransport);
     $this->client->setReconnectOptions($options);
     //Set Authid
     if (isset($options['authid'])) {
         $this->client->setAuthId($options['authid']);
     }
     //Register Handlers
     $this->handleOnChallenge();
     $this->handleOnOpen();
     $this->handleOnClose();
     $this->handleOnError();
 }
All Usage Examples Of Thruway\Peer\Client::setAuthId