Properties

$SOAP_FAULT_NAME_TO_TYPE_MAP

$SOAP_FAULT_NAME_TO_TYPE_MAP :

Type

$RESOURCES_WSDLS_PATH_FORMAT

$RESOURCES_WSDLS_PATH_FORMAT :

Type

$WSDL_FILE_EXTENSION

$WSDL_FILE_EXTENSION :

Type

$wsdlUri

$wsdlUri :

Type

$classmap

$classmap :

Type

$streamContext

$streamContext :

Type

$soapLogMessageFormatter

$soapLogMessageFormatter :

Type

$adsSession

$adsSession :

Type

$headerHandler

$headerHandler :

Type

$serviceDescriptor

$serviceDescriptor :

Type

$soapCallTimeout

$soapCallTimeout :

Type

$reflection

$reflection :

Type

$lastSoapFault

$lastSoapFault :

Type

$lastResponseHeaderValues

$lastResponseHeaderValues :

Type

Methods

__construct()

__construct(string  $wsdl,array|null  $options = null)

Creates a new instance of this SOAP client to interface with the specified WSDL (service). Do not use this constructor, instances should be created using `AdsSoapClientFactory` instead.

Parameters

string $wsdl

URI of the WSDL file or null if working in non-WSDL mode

array|null $options

the SOAP client options

__doRequest()

__doRequest(  $request,  $location,  $action,  $version,  $one_way)

Parameters

$request
$location
$action
$version
$one_way

__soapCall()

__soapCall(  $function_name,  $arguments,  $options = null,  $input_headers = null,  $output_headers = null)

Parameters

$function_name
$arguments
$options
$input_headers
$output_headers

getWsdlUri()

getWsdlUri(): string

Gets the URI of the WSDL file this SOAP client is making API calls against.

Returns

string

setStreamContext()

setStreamContext(resource  $streamContext)

Sets the stream context the SOAP client will use to make HTTP requests with. This stream context must also be set in the options when this class is constructed.

Parameters

resource $streamContext

setSoapLogMessageFormatter()

setSoapLogMessageFormatter(\Google\AdsApi\Common\SoapLogMessageFormatter  $soapLogMessageFormatter)

Sets the SOAP log message formatter.

Parameters

\Google\AdsApi\Common\SoapLogMessageFormatter $soapLogMessageFormatter

setServiceDescriptor()

setServiceDescriptor(\Google\AdsApi\Common\AdsServiceDescriptor  $serviceDescriptor)

Sets the service descriptor.

Parameters

\Google\AdsApi\Common\AdsServiceDescriptor $serviceDescriptor

getSoapCallTimeout()

getSoapCallTimeout(): integer

Gets the the time in seconds this client will wait for a SOAP call to connect to the service and respond before timing out.

Returns

integer

setSoapCallTimeout()

setSoapCallTimeout(integer  $soapCallTimeout)

Sets the SOAP call timeout.

Parameters

integer $soapCallTimeout

isLastSoapFault()

isLastSoapFault(): boolean

Returns true if there was a SOAP fault during the last call.

Returns

boolean —

true if there was a SOAP fault

getLastSoapFaultMessage()

getLastSoapFaultMessage(): string

Gets the SOAP fault message if there was any.

Returns

string —

the SOAP fault message

getLastResponseHeaderValues()

getLastResponseHeaderValues(): array

Gets the last SOAP response header values as an associative array.

Returns

array —

the SOAP response header values

parseApiExceptionFromSoapFault()

parseApiExceptionFromSoapFault(\SoapFault  $soapFault)

Parameters

\SoapFault $soapFault

processResponse()

processResponse(  $methodName,  $soapFault = null)

Parameters

$methodName
$soapFault

logSoapCall()

logSoapCall(  $methodName,\SoapFault  $soapFault = null)

Parameters

$methodName
\SoapFault $soapFault

getLocalWsdlPath()

getLocalWsdlPath(  $wsdl)

Gets the path to stored WSDLs from the provided live WSDL URI.

Parameters

$wsdl