Core/src/GrpcTrait.php
private function getGaxConfig($version, callable $authHttpHandler = null)
    {
        $config = [
            'libName' => 'gccl',
            'libVersion' => $version,
            'transport' => 'grpc'
        ];

        // GAX v0.32.0 introduced the CredentialsWrapper class and a different
        // way to configure credentials. If the class exists, use this new method
        // otherwise default to legacy usage.
        if (class_exists(CredentialsWrapper::class)) {
            $config['credentials'] = new CredentialsWrapper(
                $this->requestWrapper->getCredentialsFetcher(),
                $authHttpHandler
            );
        } else {
            $config += [
                'credentialsLoader' => $this->requestWrapper->getCredentialsFetcher(),
                'authHttpHandler' => $authHttpHandler,
                'enableCaching' => false
            ];
        }

        return $config;
    }
private function getGaxConfig($version, callable $authHttpHandler = null)
    {
        $config = [
            'libName' => 'gccl',
            'libVersion' => $version,
            'transport' => 'grpc'
        ];

        // GAX v0.32.0 introduced the CredentialsWrapper class and a different
        // way to configure credentials. If the class exists, use this new method
        // otherwise default to legacy usage.
        if (class_exists(CredentialsWrapper::class)) {
            $config['credentials'] = new CredentialsWrapper(
                $this->requestWrapper->getCredentialsFetcher(),
                $authHttpHandler
            );
        } else {
            $config += [
                'credentialsLoader' => $this->requestWrapper->getCredentialsFetcher(),
                'authHttpHandler' => $authHttpHandler,
                'enableCaching' => false
            ];
        }

        return $config;
    }
private function getGaxConfig ( $ version , callable $ authHttpHandler = null ) { $ config = [ 'libName' => 'gccl' , 'libVersion' => $ version , 'transport' => 'grpc' ] ; // GAX v0.32.0 introduced the CredentialsWrapper class and a different // way to configure credentials. If the class exists, use this new method // otherwise default to legacy usage. if ( class_exists ( CredentialsWrapper :: class ) ) { $ config [ 'credentials' ] = new CredentialsWrapper ( $ this -> requestWrapper -> getCredentialsFetcher ( ) , $ authHttpHandler ) ; } else { $ config += [ 'credentialsLoader' => $ this -> requestWrapper -> getCredentialsFetcher ( ) , 'authHttpHandler' => $ authHttpHandler , 'enableCaching' => false ] ; } return $ config ; }
Gets the default configuration for generated clients.

@param string $version
@param callable|null $authHttpHandler
@return array
Gets the default configuration for generated clients .