## nusoap_server_mime

Description

nusoap_server_mime server 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.13 2010/04/26 20:15:08 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 284)

    nusoap_base
       |
       --nusoap_server
          |
          --nusoap_server_mime

Direct descendents

Class | Description
--- | ---
nusoapservermime | nusoap_server_mime server supporting MIME attachments defined at http://www.w3.org/TR/SOAP-attachments. It depends on the PEAR Mail_MIME library.

Variable Summary
string $mimeContentType
array $requestAttachments
array $responseAttachments
Method Summary
string addAttachment (string $data, [string $filename = ''], [string $contenttype = 'application/octet-stream'], [string $cid = false])
void clearAttachments ()
array getAttachments ()
string getHTTPBody (string $soapmsg)
string getHTTPContentType ()
string getHTTPContentTypeCharset ()
mixed parseRequest (array $headers, string $data)
Variables
string $mimeContentType (line 301)

- access: private

array $requestAttachments = array() (line 290)

- var: Each array element in the return is an associative array with keys data, filename, contenttype, cid
- access: private

array $responseAttachments (line 296)

- var: Each array element in the return is an associative array with keys data, filename, contenttype, cid
- access: private

#### Inherited Variables

Inherited from nusoap_server

> nusoap_server::$debug_flag
> nusoap_server::$decode_utf8
> nusoap_server::$document
> nusoap_server::$externalWSDLURL
> nusoap_server::$fault
> nusoap_server::$headers
> nusoap_server::$methodname
> nusoap_server::$methodparams
> nusoap_server::$methodreturn
> nusoap_server::$methodreturnisliteralxml
> nusoap_server::$methodURI
> nusoap_server::$operations
> nusoap_server::$outgoing_headers
> nusoap_server::$request
> nusoap_server::$requestHeader
> nusoap_server::$requestHeaders
> nusoap_server::$requestSOAP
> nusoap_server::$response
> nusoap_server::$responseHeaders
> nusoap_server::$responseSOAP
> nusoap_server::$result
> nusoap_server::$SOAPAction
> nusoap_server::$wsdl
> nusoap_server::$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 318)

adds a MIME attachment to the current response.

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 338)

clears the MIME attachments for the current response.

- access: public

void clearAttachments ()
getAttachments (line 352)

gets the MIME attachments from the current request.

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 363)

gets the HTTP body for the current response.

- return: The HTTP body, which includes the SOAP payload
- access: private

string getHTTPBody (string $soapmsg)

- string $soapmsg: The SOAP payload

Redefinition of:

nusoap_server::getHTTPBody()
  gets the HTTP body for the current response.

getHTTPContentType (line 422)

gets the HTTP content type for the current response.

Note: getHTTPBody must be called before this.

- return: the HTTP content type for the current response.
- access: private

string getHTTPContentType ()

Redefinition of:

nusoap_server::getHTTPContentType()
  gets the HTTP content type for the current response.

getHTTPContentTypeCharset (line 438)

gets the HTTP content type charset for the current response.

returns false for non-text content types.

Note: getHTTPBody must be called before this.

- return: the HTTP content type charset for the current response.
- access: private

string getHTTPContentTypeCharset ()

Redefinition of:

nusoap_server::getHTTPContentTypeCharset()
  gets the HTTP content type charset for the current response.

parseRequest (line 453)

processes SOAP message received from client

- return: value of the message, decoded into a PHP type
- access: private

mixed parseRequest (array $headers, string $data)

- array $headers: The HTTP headers
- string $data: unprocessed request data from client

Redefinition of:

nusoap_server::parseRequest()
  processes SOAP message received from client

#### Inherited Methods

Inherited From nusoap_server

> nusoap_server::nusoap_server()
> nusoap_server::add_to_map()
> nusoap_server::configureWSDL()
> nusoap_server::fault()
> nusoap_server::getHTTPBody()
> nusoap_server::getHTTPContentType()
> nusoap_server::getHTTPContentTypeCharset()
> nusoap_server::invoke_method()
> nusoap_server::parseRequest()
> nusoap_server::parse_http_headers()
> nusoap_server::parse_request()
> nusoap_server::register()
> nusoap_server::send_response()
> nusoap_server::serialize_return()
> nusoap_server::service()
> nusoap_server::verify_method()

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 Mon, 26 Apr 2010 16:17:10 -0400 by phpDocumentor 1.3.0RC3