Open Journal Systems  2.4.3
 All Classes Namespaces Functions Variables Groups Pages
JSONMessage Class Reference

Public Member Functions

 getAdditionalAttributes ()
 
 getContent ()
 
 getElementId ()
 
 getEvent ()
 
 getStatus ()
 
 getString ()
 
 JSONMessage ($status=true, $content= '', $elementId= '0', $additionalAttributes=null)
 
 setAdditionalAttributes ($additionalAttributes)
 
 setContent ($content)
 
 setElementId ($elementId)
 
 setEvent ($eventName, $eventData=null)
 
 setSimulatePhp4 ($simulatePhp4)
 
 setStatus ($status)
 

Detailed Description

Class to represent a JSON (Javascript Object Notation) message.

Definition at line 18 of file JSONMessage.inc.php.

Member Function Documentation

JSONMessage::getAdditionalAttributes ( )

Get the additionalAttributes array

Returns
array

Definition at line 131 of file JSONMessage.inc.php.

Referenced by getString().

JSONMessage::getContent ( )

Get the content string

Returns
mixed

Definition at line 75 of file JSONMessage.inc.php.

Referenced by getString().

JSONMessage::getElementId ( )

Get the elementId string

Returns
string

Definition at line 91 of file JSONMessage.inc.php.

Referenced by getString().

JSONMessage::getEvent ( )

Get the event to trigger with this JSON message

Returns
array

Definition at line 123 of file JSONMessage.inc.php.

Referenced by getString().

JSONMessage::getStatus ( )

Get the status string

Returns
string

Definition at line 58 of file JSONMessage.inc.php.

Referenced by getString().

JSONMessage::JSONMessage (   $status = true,
  $content = '',
  $elementId = '0',
  $additionalAttributes = null 
)

Constructor.

Parameters
$statusboolean The status of an event (e.g. false if form validation fails).
$contentMixed The message to be delivered back to the calling script.
$elementIdstring The DOM element to be replaced.
$additionalAttributesarray Additional data to be returned.

Definition at line 44 of file JSONMessage.inc.php.

References setAdditionalAttributes(), setContent(), setElementId(), and setStatus().

JSONMessage::setAdditionalAttributes (   $additionalAttributes)

Set the additionalAttributes array

Parameters
$additionalAttributesarray

Definition at line 139 of file JSONMessage.inc.php.

Referenced by JSONMessage().

JSONMessage::setContent (   $content)

Set the content data

Parameters
$contentmixed

Definition at line 83 of file JSONMessage.inc.php.

Referenced by JSONMessage().

JSONMessage::setElementId (   $elementId)

Set the elementId string

Parameters
$elementIdstring

Definition at line 99 of file JSONMessage.inc.php.

Referenced by JSONMessage().

JSONMessage::setEvent (   $eventName,
  $eventData = null 
)

Set the event to trigger with this JSON message

Parameters
$eventNamestring
$eventDatastring

Definition at line 109 of file JSONMessage.inc.php.

JSONMessage::setSimulatePhp4 (   $simulatePhp4)

Set to simulate a PHP4 environment. This is for internal use in unit tests only.

Parameters
$simulatePhp4boolean

Definition at line 149 of file JSONMessage.inc.php.

JSONMessage::setStatus (   $status)

Set the status string

Parameters
$statusstring

Definition at line 66 of file JSONMessage.inc.php.

Referenced by JSONMessage().


The documentation for this class was generated from the following file: