src/ServiceBus/Internal/WrapRestProxy.php
public function wrapAccessToken($uri, $name, $password, $scope)
    {
        $method = Resources::HTTP_POST;
        $headers = [];
        $queryParams = [];
        $postParameters = [];
        $statusCode = Resources::STATUS_OK;

        $postParameters = $this->addPostParameter(
            $postParameters,
            Resources::WRAP_NAME,
            $name
        );

        $postParameters = $this->addPostParameter(
            $postParameters,
            Resources::WRAP_PASSWORD,
            $password
        );

        $postParameters = $this->addPostParameter(
            $postParameters,
            Resources::WRAP_SCOPE,
            $scope
        );

        $this->setUri($uri);

        $response = $this->sendHttp(
            $method,
            $headers,
            $queryParams,
            $postParameters,
            Resources::EMPTY_STRING,
            $statusCode
        );

        return WrapAccessTokenResult::create($response->getBody());
    }
public function wrapAccessToken($uri, $name, $password, $scope)
    {
        $method = Resources::HTTP_POST;
        $headers = [];
        $queryParams = [];
        $postParameters = [];
        $statusCode = Resources::STATUS_OK;

        $postParameters = $this->addPostParameter(
            $postParameters,
            Resources::WRAP_NAME,
            $name
        );

        $postParameters = $this->addPostParameter(
            $postParameters,
            Resources::WRAP_PASSWORD,
            $password
        );

        $postParameters = $this->addPostParameter(
            $postParameters,
            Resources::WRAP_SCOPE,
            $scope
        );

        $this->setUri($uri);

        $response = $this->sendHttp(
            $method,
            $headers,
            $queryParams,
            $postParameters,
            Resources::EMPTY_STRING,
            $statusCode
        );

        return WrapAccessTokenResult::create($response->getBody());
    }
public function wrapAccessToken ( $ uri , $ name , $ password , $ scope ) { $ method = Resources :: HTTP_POST ; $ headers = [ ] ; $ queryParams = [ ] ; $ postParameters = [ ] ; $ statusCode = Resources :: STATUS_OK ; $ postParameters = $ this -> addPostParameter ( $ postParameters , Resources :: WRAP_NAME , $ name ) ; $ postParameters = $ this -> addPostParameter ( $ postParameters , Resources :: WRAP_PASSWORD , $ password ) ; $ postParameters = $ this -> addPostParameter ( $ postParameters , Resources :: WRAP_SCOPE , $ scope ) ; $ this -> setUri ( $ uri ) ; $ response = $ this -> sendHttp ( $ method , $ headers , $ queryParams , $ postParameters , Resources :: EMPTY_STRING , $ statusCode ) ; return WrapAccessTokenResult :: create ( $ response -> getBody ( ) ) ; }
Gets a WRAP access token with specified parameters.

@param string $uri      The URI of the WRAP service
@param string $name     The user name of the WRAP service
@param string $password The password of the WRAP service
@param string $scope    The scope of the WRAP service

@return WrapAccessTokenResult
Gets a WRAP access token with specified parameters .