Thruway\Peer\Client::start PHP Method

start() public method

Start the transport
public start ( boolean $startLoop = true )
$startLoop boolean
    public function start($startLoop = true)
    {
        if ($this->transportProvider === null) {
            throw new \Exception("You must add exactly one transport provider prior to starting");
        }
        $this->transportProvider->startTransportProvider($this, $this->loop);
        if ($startLoop) {
            $this->loop->run();
        }
    }

Usage Example

Example #1
0
 /**
  * Start the transport
  *
  * @param boolean $startLoop
  * @throws \Exception
  */
 public function start($debug = false, $startLoop = true)
 {
     if (!$debug) {
         Logger::set(new NullLogger());
     }
     parent::start($startLoop);
 }
All Usage Examples Of Thruway\Peer\Client::start