\FOFHalRenderJson
Implements the HAL over JSON renderer
Synopsis
class FOFHalRenderJson
implements
FOFHalRenderInterface
{
- // members
- private $_dataKey;
- protected FOFHalDocument $_document;
- // methods
- public void __construct()
- public string render()
- protected stdClass _getLink()
Hierarchy
Implements
Members
private
- $_dataKey
—
string
When data is an array we'll output the list of data under this key
protected
- $_document
—
FOFHalDocument
The document to render
Methods
protected
- _getLink() — Converts a FOFHalLink object into a stdClass object which will be used for JSON serialisation
public
- __construct() — Public constructor
- render() — Render a HAL document in JSON format