Class nusoap_base

Description

nusoap_base

Located in /nusoap.php (line 86)


	
			
Direct descendents
Class Description
 class nusoap_fault Contains information for a SOAP fault.
 class nusoap_xmlschema parses an XML Schema, allows access to it's data, other utility methods.
 class soapval For creating serializable abstractions of native PHP types. This class
 class soap_transport_http transport class for sending/receiving data via HTTP and HTTPS NOTE: PHP must be compiled with the CURL extension for HTTPS support
 class nusoap_server nusoap_server allows the user to create a SOAP server that is capable of receiving messages and returning responses
 class wsdl parses a WSDL file, allows access to it's data, other utility methods.
 class nusoap_parser nusoap_parser class parses SOAP XML messages into native PHP values
 class nusoap_client [nu]soapclient higher level class for easy usage.
Variable Summary
 boolean $charencoding
 integer $debugLevel
 string $debug_str
 string $error_str
 array $namespaces
 string $revision
 string $title
 array $typemap
 string $version
 array $xmlEntities
Method Summary
 nusoap_base nusoap_base ()
 void appendDebug (string $string)
 void clearDebug ()
 string contractQname (string $qname)
 void debug (string $string)
 void expandEntities (string $val)
 string expandQname (string $qname)
 string formatDump (string $str)
 debug &getDebug ()
 int getDebugLevel ()
 mixed getError ()
 integer getGlobalDebugLevel ()
 string getLocalPart (string $str)
 string getmicrotime ()
 mixed getNamespaceFromPrefix (string $prefix)
 mixed getPrefix (string $str)
 mixed getPrefixFromNamespace (string $ns)
 string isArraySimpleOrStruct (mixed $val)
 string serializeEnvelope (string $body, [mixed $headers = false], [array $namespaces = array()], [string $style = 'rpc'], [string $use = 'encoded'], [string $encodingStyle = 'http://schemas.xmlsoap.org/soap/encoding/'])
 string serialize_val (mixed $val, [string $name = false], [string $type = false], [string $name_ns = false], [string $type_ns = false], [array $attributes = false], [string $use = 'encoded'], [boolean $soapval = false])
 void setDebugLevel (int $level)
 boolean setError (mixed $str)
 void setGlobalDebugLevel (int $level)
 string varDump (mixed $data)
 string __toString ()
Variables
boolean $charencoding = true (line 129)

toggles automatic encoding of special characters as entities (should always be true, I think)

  • access: private
integer $debugLevel (line 136)

the debug level for this instance

  • access: private
string $debug_str = '' (line 121)

Current debug string (manipulated by debug/appendDebug/clearDebug/getDebug/getDebugAsXMLComment)

  • access: private
string $error_str = '' (line 114)

Current error string (manipulated by getError/setError)

  • access: private
array $namespaces = array(
'SOAP-ENV' => 'http://schemas.xmlsoap.org/soap/envelope/',
'xsd' => 'http://www.w3.org/2001/XMLSchema',
'xsi' => 'http://www.w3.org/2001/XMLSchema-instance',
'SOAP-ENC' => 'http://schemas.xmlsoap.org/soap/encoding/'
)
(line 163)

namespaces in an array of prefix => uri

this is "seeded" by a set of constants, but it may be altered by code

  • access: public

Redefined in descendants as:
string $revision = '$Revision: 1.113 $' (line 107)

CVS revision for HTTP headers.

  • access: private
string $soap_defencoding = 'ISO-8859-1' (line 152)

charset encoding for outgoing messages

  • access: public
string $title = 'NuSOAP' (line 93)

Identification for HTTP headers.

  • access: private
array $typemap = array(
'http://www.w3.org/2001/XMLSchema' => array(
'string'=>'string','boolean'=>'boolean','float'=>'double','double'=>'double','decimal'=>'double',
'duration'=>'','dateTime'=>'string','time'=>'string','date'=>'string','gYearMonth'=>'',
'gYear'=>'','gMonthDay'=>'','gDay'=>'','gMonth'=>'','hexBinary'=>'string','base64Binary'=>'string',
// abstract "any" types
'anyType'=>'string','anySimpleType'=>'string',
// derived datatypes
'normalizedString'=>'string','token'=>'string','language'=>'','NMTOKEN'=>'','NMTOKENS'=>'','Name'=>'','NCName'=>'','ID'=>'',
'IDREF'=>'','IDREFS'=>'','ENTITY'=>'','ENTITIES'=>'','integer'=>'integer','nonPositiveInteger'=>'integer',
'negativeInteger'=>'integer','long'=>'integer','int'=>'integer','short'=>'integer','byte'=>'integer','nonNegativeInteger'=>'integer',
'unsignedLong'=>'','unsignedInt'=>'','unsignedShort'=>'','unsignedByte'=>'','positiveInteger'=>''),'http://www.w3.org/2000/10/XMLSchema'=>array('i4'=>'','int'=>'integer','boolean'=>'boolean','string'=>'string','double'=>'double','float'=>'double','dateTime'=>'string','timeInstant'=>'string','base64Binary'=>'string','base64'=>'string','ur-type'=>'array'),'http://www.w3.org/1999/XMLSchema'=>array('i4'=>'','int'=>'integer','boolean'=>'boolean','string'=>'string','double'=>'double','float'=>'double','dateTime'=>'string','timeInstant'=>'string','base64Binary'=>'string','base64'=>'string','ur-type'=>'array'),'http://soapinterop.org/xsd'=>array('SOAPStruct'=>'struct'),'http://schemas.xmlsoap.org/soap/encoding/'=>array('base64'=>'string','array'=>'array','Array'=>'array'),'http://xml.apache.org/xml-soap'=>array('Map'))
(line 185)

XML Schema types in an array of uri => (array of xml type => php type) is this legacy yet? no, this is used by the nusoap_xmlschema class to verify type => namespace mappings.

  • access: public
array $usedNamespaces = array() (line 176)

namespaces used in the current context, e.g. during serialization

  • access: private
string $version = '0.7.2' (line 100)

Version for HTTP headers.

  • access: private
array $xmlEntities = array('quot' => '"','amp' => '&',
'lt' => '<','gt' => '>','apos' => "'")
(line 218)

XML entities to convert

string $XMLSchemaVersion = 'http://www.w3.org/2001/XMLSchema' (line 144)

set schema version

  • access: public
Methods
Constructor nusoap_base (line 226)

constructor

  • access: public
nusoap_base nusoap_base ()
appendDebug (line 288)

adds debug data to the instance debug string without formatting

  • access: public
void appendDebug (string $string)
  • string $string: debug data
clearDebug (line 301)

clears the current debug data for this instance

  • access: public
void clearDebug ()
contractQname (line 741)

contracts (changes namespace to prefix) a qualified name

  • return: contracted qname
  • access: private
string contractQname (string $qname)
  • string $qname: qname
debug (line 276)

adds debug data to the instance debug string with formatting

  • access: private
void debug (string $string)
  • string $string: debug data
expandEntities (line 342)

expands entities, e.g. changes '<' to '&lt;'.

  • access: private
void expandEntities (string $val)
  • string $val: The string in which to expand entities.
expandQname (line 766)

expands (changes prefix to namespace) a qualified name

  • return: expanded qname
  • access: private
string expandQname (string $qname)
  • string $qname: qname
formatDump (line 729)

formats a string to be inserted into an HTML stream

  • return: The formatted string
  • deprecated:
  • access: public
string formatDump (string $str)
  • string $str: The string to format
getDebug (line 313)

gets the current debug data for this instance

  • return: data
  • access: public
debug &getDebug ()
getDebugAsXMLComment (line 326)

gets the current debug data for this instance as an XML comment this may change the contents of the debug data

  • return: data as an XML comment
  • access: public
debug &getDebugAsXMLComment ()
getDebugLevel (line 256)

gets the debug level for this instance

  • return: Debug level 0-9, where 0 turns off
  • access: public
int getDebugLevel ()
getError (line 359)

returns error string if present

  • return: error string or false
  • access: public
mixed getError ()
getGlobalDebugLevel (line 236)

gets the global debug level, which applies to future instances

  • return: Debug level 0-9, where 0 turns off
  • access: public
integer getGlobalDebugLevel ()
getLocalPart (line 791)

returns the local part of a prefixed string returns the original string, if not prefixed

  • return: The local part
  • access: public
string getLocalPart (string $str)
  • string $str: The prefixed string
getmicrotime (line 855)

returns the time in ODBC canonical form with microseconds

  • return: The time in ODBC canonical form with microseconds
  • access: public
string getmicrotime ()
getNamespaceFromPrefix (line 823)

pass it a prefix, it returns a namespace

  • return: The namespace, false if no namespace has the specified prefix
  • access: public
mixed getNamespaceFromPrefix (string $prefix)
  • string $prefix: The prefix
getPrefix (line 808)

returns the prefix part of a prefixed string returns false, if not prefixed

  • return: The prefix or false if there is no prefix
  • access: public
mixed getPrefix (string $str)
  • string $str: The prefixed string
getPrefixFromNamespace (line 839)

returns the prefix for a given namespace (or prefix) or false if no prefixes registered for the given namespace

  • return: The prefix, false if the namespace has no prefixes
  • access: public
mixed getPrefixFromNamespace (string $ns)
  • string $ns: The namespace
isArraySimpleOrStruct (line 383)

detect if array is a simple array or a struct (associative array)

  • return: (arraySimple|arrayStruct)
  • access: private
string isArraySimpleOrStruct (mixed $val)
  • mixed $val: The PHP array
serializeEnvelope (line 674)

serializes a message

  • return: the message
  • access: public
string serializeEnvelope (string $body, [mixed $headers = false], [array $namespaces = array()], [string $style = 'rpc'], [string $use = 'encoded'], [string $encodingStyle = 'http://schemas.xmlsoap.org/soap/encoding/'])
  • string $body: the XML of the SOAP body
  • mixed $headers: optional string of XML with SOAP header content, or array of soapval objects for SOAP headers, or associative array
  • array $namespaces: optional the namespaces used in generating the body and headers
  • string $style: optional (rpc|document)
  • string $use: optional (encoded|literal)
  • string $encodingStyle: optional (usually 'http://schemas.xmlsoap.org/soap/encoding/' for encoded)
serialize_val (line 408)

serializes PHP values in accordance w/ section 5. Type information is not serialized if $use == 'literal'.

  • return: The serialized element, possibly with child elements
  • access: public
string serialize_val (mixed $val, [string $name = false], [string $type = false], [string $name_ns = false], [string $type_ns = false], [array $attributes = false], [string $use = 'encoded'], [boolean $soapval = false])
  • mixed $val: The value to serialize
  • string $name: The name (local part) of the XML element
  • string $type: The XML schema type (local part) for the element
  • string $name_ns: The namespace for the name of the XML element
  • string $type_ns: The namespace for the type of the element
  • array $attributes: The attributes to serialize as name=>value pairs
  • string $use: The WSDL "use" (encoded|literal)
  • boolean $soapval: Whether this is called from soapval.
setDebugLevel (line 266)

sets the debug level for this instance

  • access: public
void setDebugLevel (int $level)
  • int $level: Debug level 0-9, where 0 turns off
setError (line 372)

sets error string

  • return: error string
  • access: private
boolean setError (mixed $str)
setGlobalDebugLevel (line 246)

sets the global debug level, which applies to future instances

  • access: public
void setGlobalDebugLevel (int $level)
  • int $level: Debug level 0-9, where 0 turns off
varDump (line 874)

Returns a string with the output of var_dump

  • return: The output of var_dump
  • access: public
string varDump (mixed $data)
  • mixed $data: The variable to var_dump
__toString (line 888)

represents the object as a string

  • access: public
string __toString ()

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