Class QJsClosure
Class QJsClosure
An object which represents a javascript closure (annonymous function). Use this to embed a function into a PHP array or object that eventually will get turned into javascript.
- QJsClosure implements JsonSerializable
public
|
|
public
string
|
#
toJsObject( )
Return a javascript enclosure. Enclosures cannot be included in JSON, so we need to create a custom encoding to include in the json that will get decoded at the other side. |
public
mixed
|
#
jsonSerialize( )
Converts the object into something serializable by json_encode. Will get decoded in qcubed.unpackObj |
protected
string
|
$strBody
The js code for the function. |
|
protected
array
|
$strParamsArray
parameter names for the function call that get passed into the function. |