src/Google/AdsApi/Common/AdsHeaderFormatter.php
public function formatApplicationNameForSoapHeader(
        $applicationName,
        $productNameForSoapHeader,
        $includeUtilityUsage
    ) {
        $adsUtilities = $this->adsUtilityRegistry->popAllUtilities();

        return sprintf(
            '%s (%sApi-PHP, %s/%s, PHP/%s%s)',
            $applicationName,
            $productNameForSoapHeader,
            $this->libraryMetadataProvider->getLibName(),
            $this->libraryMetadataProvider->getLibVersion(),
            PHP_VERSION,
            $this->formatUtilUsages($adsUtilities, $includeUtilityUsage)
        );
    }
public function formatApplicationNameForSoapHeader(
        $applicationName,
        $productNameForSoapHeader,
        $includeUtilityUsage
    ) {
        $adsUtilities = $this->adsUtilityRegistry->popAllUtilities();

        return sprintf(
            '%s (%sApi-PHP, %s/%s, PHP/%s%s)',
            $applicationName,
            $productNameForSoapHeader,
            $this->libraryMetadataProvider->getLibName(),
            $this->libraryMetadataProvider->getLibVersion(),
            PHP_VERSION,
            $this->formatUtilUsages($adsUtilities, $includeUtilityUsage)
        );
    }
public function formatApplicationNameForSoapHeader ( $ applicationName , $ productNameForSoapHeader , $ includeUtilityUsage ) { $ adsUtilities = $ this -> adsUtilityRegistry -> popAllUtilities ( ) ; return sprintf ( '%s (%sApi-PHP, %s/%s, PHP/%s%s)' , $ applicationName , $ productNameForSoapHeader , $ this -> libraryMetadataProvider -> getLibName ( ) , $ this -> libraryMetadataProvider -> getLibVersion ( ) , PHP_VERSION , $ this -> formatUtilUsages ( $ adsUtilities , $ includeUtilityUsage ) ) ; }
Formats an application name in a format standard to the ads libraries to
include in the SOAP header.

@param string $applicationName the application name to format
@param string $productNameForSoapHeader the ads product API calls are
being made against, formatted to be used in the SOAP header
@param boolean $includeUtilityUsage true if logging of utilities usages is
turned on
@return string the formatted application name
Formats an application name in a format standard to the ads libraries to include in the SOAP header .