\Zend_Amf_Parse_Amf3_Serializer

Detect PHP object type and convert it to a corresponding AMF3 object type

Summary

Methods
Properties
Constants
__construct()
writeTypeMarker()
writeInteger()
writeString()
writeByteArray()
writeXml()
writeDate()
writeArray()
writeObject()
No public properties found
No constants found
writeBinaryString()
writeObjectReference()
$_stream
$_referenceObjects
$_referenceStrings
$_referenceDefinitions
N/A
No private methods found
No private properties found
N/A

Properties

$_stream

$_stream : string

Refrence to the current output stream being constructed

Type

string

$_referenceObjects

$_referenceObjects : array

An array of reference objects per amf body

Type

array

$_referenceStrings

$_referenceStrings : array

An array of reference strings per amf body

Type

array

$_referenceDefinitions

$_referenceDefinitions : array

An array of reference class definitions, indexed by classname

Type

array

Methods

writeTypeMarker()

writeTypeMarker(  $data, integer  $markerType = null) : void

Serialize PHP types to AMF3 and write to stream

Checks to see if the type was declared and then either auto negotiates the type or use the user defined markerType to serialize the data from php back to AMF3

Parameters

$data
integer $markerType

writeString()

writeString(string  $string) : \Zend_Amf_Parse_Amf3_Serializer

Send string to output stream

Parameters

string $string

Returns

\Zend_Amf_Parse_Amf3_Serializer

writeXml()

writeXml(\DOMDocument|\SimpleXMLElement  $xml) : \Zend_Amf_Parse_Amf3_Serializer

Send xml to output stream

Parameters

\DOMDocument|\SimpleXMLElement $xml

Returns

\Zend_Amf_Parse_Amf3_Serializer

writeArray()

writeArray(array  $array) : \Zend_Amf_Parse_Amf3_Serializer

Write a PHP array back to the amf output stream

Parameters

array $array

Returns

\Zend_Amf_Parse_Amf3_Serializer

writeObject()

writeObject(  $object) : \Zend_Amf_Parse_Amf3_Serializer

Write object to ouput stream

Parameters

$object

Returns

\Zend_Amf_Parse_Amf3_Serializer

writeBinaryString()

writeBinaryString(string  $string) : \Zend_Amf_Parse_Amf3_Serializer

Send string to output stream, without trying to reference it.

The string is prepended with strlen($string) << 1 | 0x01

Parameters

string $string

Returns

\Zend_Amf_Parse_Amf3_Serializer

writeObjectReference()

writeObjectReference(mixed  $object) : Boolean

Check if the given object is in the reference table, write the reference if it exists, otherwise add the object to the reference table

Parameters

mixed $object

object to check for reference

Returns

Boolean —

true, if the reference was written, false otherwise