public function getHandlerStack(): HandlerStack
    {
        if ($this->handlerStack) {
            return $this->handlerStack;
        }

        $this->handlerStack = HandlerStack::create($this->getGuzzleHandler());

        foreach ($this->middlewares as $name => $middleware) {
            $this->handlerStack->push($middleware, $name);
        }

        return $this->handlerStack;
    }
public function getHandlerStack(): HandlerStack
    {
        if ($this->handlerStack) {
            return $this->handlerStack;
        }

        $this->handlerStack = HandlerStack::create($this->getGuzzleHandler());

        foreach ($this->middlewares as $name => $middleware) {
            $this->handlerStack->push($middleware, $name);
        }

        return $this->handlerStack;
    }
public function getHandlerStack ( ) : HandlerStack { if ( $ this -> handlerStack ) { return $ this -> handlerStack ; } $ this -> handlerStack = HandlerStack :: create ( $ this -> getGuzzleHandler ( ) ) ; foreach ( $ this -> middlewares as $ name => $ middleware ) { $ this -> handlerStack -> push ( $ middleware , $ name ) ; } return $ this -> handlerStack ; }
Build a handler stack.

@return \GuzzleHttp\HandlerStack
Build a handler stack .