PAMI\Client\Impl\ClientImpl::close PHP Method

close() public method

Closes the connection to ami.
public close ( ) : void
return void
    public function close()
    {
        $this->logger->debug('Closing connection to asterisk.');
        @stream_socket_shutdown($this->socket, STREAM_SHUT_RDWR);
    }

Usage Example

コード例 #1
0
ファイル: Client.php プロジェクト: thomasvargiu/pami-module
 /**
  * Disconnect from the Asterisk Manager Interface.
  *
  * @return $this
  */
 public function disconnect()
 {
     $results = $this->getEventManager()->trigger(__FUNCTION__ . '.pre', $this);
     if ($results->stopped()) {
         return $this;
     }
     $this->connection->close();
     $this->getEventManager()->trigger(__FUNCTION__ . '.post', $this);
     return $this;
 }
All Usage Examples Of PAMI\Client\Impl\ClientImpl::close