mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-27 10:23:28 +01:00
add missing functions; used when outputbuffering is active; may not be complete; as we never use InitResponseArray
This commit is contained in:
parent
ee4ceba548
commit
3367609f45
@ -195,6 +195,16 @@ class egw_json_response
|
||||
return isset(self::$response);
|
||||
}
|
||||
|
||||
/**
|
||||
* Do we have a JSON response to send back
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function haveJSONResponse()
|
||||
{
|
||||
return (boolean) $this->responseArray;
|
||||
}
|
||||
|
||||
/**
|
||||
* Private function used to send the HTTP header of the JSON response
|
||||
*/
|
||||
@ -260,6 +270,20 @@ class egw_json_response
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Init responseArray
|
||||
*
|
||||
* @param array $arr
|
||||
* @return array previous content
|
||||
*/
|
||||
public function initResponseArray()
|
||||
{
|
||||
$return = $this->responseArray;
|
||||
$this->responseArray = array();
|
||||
$this->hasData = false;
|
||||
return $return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds a "data" response to the json response.
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user