Class nusoap_client_mime

Description

nusoap_client_mime client supporting MIME attachments defined at http://www.w3.org/TR/SOAP-attachments. It depends on the PEAR Mail_MIME library.

  • access: public
  • version: $Id: nusoapmime.php,v 1.12 2007/04/17 16:34:03 snichol Exp $
  • author: Scott Nichol <snichol@users.sourceforge.net>
  • author: Thanks to Guillaume and Henning Reich for posting great attachment code to the mail list

Located in /nusoapmime.php (line 54)

nusoap_base
   |
   --nusoap_client
      |
      --nusoap_client_mime
Direct descendents
Class Description
 class soapclientmime nusoap_client_mime client supporting MIME attachments defined at http://www.w3.org/TR/SOAP-attachments. It depends on the PEAR Mail_MIME library.
Variable Summary
Method Summary
 string addAttachment (string $data, [string $filename = ''], [string $contenttype = 'application/octet-stream'], [string $cid = false])
 array getAttachments ()
 string getHTTPBody (string $soapmsg)
 string getHTTPContentType ()
 mixed parseResponse (array $headers, string $data)
Variables
string $mimeContentType (line 71)
  • access: private
array $requestAttachments = array() (line 60)
  • var: Each array element in the return is an associative array with keys data, filename, contenttype, cid
  • access: private
array $responseAttachments (line 66)
  • var: Each array element in the return is an associative array with keys data, filename, contenttype, cid
  • access: private

Inherited Variables

Inherited from nusoap_client

nusoap_client::$authtype
nusoap_client::$bindingType
nusoap_client::$certRequest
nusoap_client::$cookies
nusoap_client::$curl_options
nusoap_client::$decode_utf8
nusoap_client::$defaultRpcParams
nusoap_client::$document
nusoap_client::$endpoint
nusoap_client::$endpointType
nusoap_client::$fault
nusoap_client::$faultcode
nusoap_client::$faultdetail
nusoap_client::$faultstring
nusoap_client::$forceEndpoint
nusoap_client::$http_encoding
nusoap_client::$operations
nusoap_client::$password
nusoap_client::$persistentConnection
nusoap_client::$proxyhost
nusoap_client::$proxypassword
nusoap_client::$proxyport
nusoap_client::$proxyusername
nusoap_client::$request
nusoap_client::$requestHeaders
nusoap_client::$response
nusoap_client::$responseData
nusoap_client::$responseHeader
nusoap_client::$responseHeaders
nusoap_client::$response_timeout
nusoap_client::$timeout
nusoap_client::$username
nusoap_client::$use_curl
nusoap_client::$xml_encoding

Inherited from nusoap_base

nusoap_base::$charencoding
nusoap_base::$debugLevel
nusoap_base::$debug_str
nusoap_base::$error_str
nusoap_base::$namespaces
nusoap_base::$revision
nusoap_base::$soap_defencoding
nusoap_base::$title
nusoap_base::$typemap
nusoap_base::$usedNamespaces
nusoap_base::$version
nusoap_base::$xmlEntities
nusoap_base::$XMLSchemaVersion
Methods
addAttachment (line 88)

adds a MIME attachment to the current request.

If the $data parameter contains an empty string, this method will read the contents of the file named by the $filename parameter.

If the $cid parameter is false, this method will generate the cid.

  • return: The content-id (cid) of the attachment
  • access: public
string addAttachment (string $data, [string $filename = ''], [string $contenttype = 'application/octet-stream'], [string $cid = false])
  • string $data: The data of the attachment
  • string $filename: The filename of the attachment (default is empty string)
  • string $contenttype: The MIME Content-Type of the attachment (default is application/octet-stream)
  • string $cid: The content-id (cid) of the attachment (default is false)
clearAttachments (line 108)

clears the MIME attachments for the current request.

  • access: public
void clearAttachments ()
getAttachments (line 122)

gets the MIME attachments from the current response.

Each array element in the return is an associative array with keys data, filename, contenttype, cid. These keys correspond to the parameters for addAttachment.

  • return: The attachments.
  • access: public
array getAttachments ()
getHTTPBody (line 133)

gets the HTTP body for the current request.

  • return: The HTTP body, which includes the SOAP payload
  • access: private
string getHTTPBody (string $soapmsg)
  • string $soapmsg: The SOAP payload

Redefinition of:
nusoap_client::getHTTPBody()
gets the HTTP body for the current request.
getHTTPContentType (line 192)

gets the HTTP content type for the current request.

Note: getHTTPBody must be called before this.

  • return: the HTTP content type for the current request.
  • access: private
string getHTTPContentType ()

Redefinition of:
nusoap_client::getHTTPContentType()
gets the HTTP content type for the current request.
getHTTPContentTypeCharset (line 208)

gets the HTTP content type charset for the current request.

returns false for non-text content types.

Note: getHTTPBody must be called before this.

  • return: the HTTP content type charset for the current request.
  • access: private
string getHTTPContentTypeCharset ()

Redefinition of:
nusoap_client::getHTTPContentTypeCharset()
gets the HTTP content type charset for the current request.
parseResponse (line 223)

processes SOAP message returned from server

  • return: value of the message, decoded into a PHP type
  • access: private
mixed parseResponse (array $headers, string $data)
  • array $headers: The HTTP headers
  • string $data: unprocessed response data from server

Redefinition of:
nusoap_client::parseResponse()
processes SOAP message returned from server

Inherited Methods

Inherited From nusoap_client

 nusoap_client::nusoap_client()
 nusoap_client::call()
 nusoap_client::checkCookies()
 nusoap_client::checkWSDL()
 nusoap_client::decodeUTF8()
 nusoap_client::getCookies()
 nusoap_client::getDefaultRpcParams()
 nusoap_client::getHeader()
 nusoap_client::getHeaders()
 nusoap_client::getHTTPBody()
 nusoap_client::getHTTPContentType()
 nusoap_client::getHTTPContentTypeCharset()
 nusoap_client::getOperationData()
 nusoap_client::getProxy()
 nusoap_client::getProxyClassCode()
 nusoap_client::loadWSDL()
 nusoap_client::parseResponse()
 nusoap_client::send()
 nusoap_client::setCookie()
 nusoap_client::setCredentials()
 nusoap_client::setCurlOption()
 nusoap_client::setDefaultRpcParams()
 nusoap_client::setEndpoint()
 nusoap_client::setHeaders()
 nusoap_client::setHTTPEncoding()
 nusoap_client::setHTTPProxy()
 nusoap_client::setUseCURL()
 nusoap_client::UpdateCookies()
 nusoap_client::useHTTPPersistentConnection()
 nusoap_client::_getProxyClassCode()

Inherited From nusoap_base

 nusoap_base::nusoap_base()
 nusoap_base::appendDebug()
 nusoap_base::clearDebug()
 nusoap_base::contractQname()
 nusoap_base::debug()
 nusoap_base::expandEntities()
 nusoap_base::expandQname()
 nusoap_base::formatDump()
 nusoap_base::getDebug()
 nusoap_base::getDebugAsXMLComment()
 nusoap_base::getDebugLevel()
 nusoap_base::getError()
 nusoap_base::getGlobalDebugLevel()
 nusoap_base::getLocalPart()
 nusoap_base::getmicrotime()
 nusoap_base::getNamespaceFromPrefix()
 nusoap_base::getPrefix()
 nusoap_base::getPrefixFromNamespace()
 nusoap_base::isArraySimpleOrStruct()
 nusoap_base::serializeEnvelope()
 nusoap_base::serialize_val()
 nusoap_base::setDebugLevel()
 nusoap_base::setError()
 nusoap_base::setGlobalDebugLevel()
 nusoap_base::varDump()
 nusoap_base::__toString()

Documentation generated on Tue, 06 Nov 2007 10:40:24 -0500 by phpDocumentor 1.3.0RC3