1853. Class

1853.1. Zend\View\Strategy\JsonStrategy

1853.1.1. Methods

1853.1.1.1. __construct

__construct()

Constructor

Parameters:JsonRenderer

1853.1.1.2. attach

attach()

Attach the aggregate to the specified event manager

Parameters:
  • EventManagerInterface
  • int
Return type:

void

1853.1.1.3. detach

detach()

Detach aggregate listeners from the specified event manager

Parameters:EventManagerInterface
Return type:void

1853.1.1.4. setCharset

setCharset()

Set the content-type character set

Parameters:string
Return type:JsonStrategy

1853.1.1.5. getCharset

getCharset()

Retrieve the current character set

Return type:string

1853.1.1.6. selectRenderer

selectRenderer()

Detect if we should use the JsonRenderer based on model type and/or Accept header

Parameters:ViewEvent
Return type:null|JsonRenderer

1853.1.1.7. injectResponse

injectResponse()

Inject the response with the JSON payload and appropriate Content-Type header

Parameters:ViewEvent
Return type:void