Class ViewEvent

Summary

Fully Qualified Name: Laminas\View\ViewEvent
Extends: Event

Description

Methods

Name Description Defined By
__construct() Constructor Event
getModel() Retrieve the view model ViewEvent
getName() Get event name Event
getParam() Get event parameter ViewEvent
getParams() Get all event parameters ViewEvent
getRenderer() Get value for renderer ViewEvent
getRequest() Retrieve the MVC request object ViewEvent
getResponse() Retrieve the MVC response object ViewEvent
getResult() Retrieve the result of rendering ViewEvent
getTarget() Get the event target Event
propagationIsStopped() Is propagation stopped? Event
setModel() Set the view model ViewEvent
setName() Set the event name Event
setParam() Set an individual event parameter ViewEvent
setParams() Set event parameters ViewEvent
setRenderer() Set value for renderer ViewEvent
setRequest() Set the MVC request object ViewEvent
setResponse() Set the MVC response object ViewEvent
setResult() Set result of rendering ViewEvent
setTarget() Set the event target/context Event
stopPropagation() Stop further event propagation Event

Method Details

__construct()

Constructor

Accept a target and its parameters.

Parameter Name Type Description
$name string Event
$target string|object
$params array|\ArrayAccess

Returns:

getModel()

Retrieve the view model

Returns: null|\Model

getName()

Get event name

Returns: string

getParam()

Get event parameter

Parameter Name Type Description
$name string
$default mixed

Returns: mixed

getParams()

Get all event parameters

Returns: array|\ArrayAccess

getRenderer()

Get value for renderer

Returns: null|\Renderer

getRequest()

Retrieve the MVC request object

Returns: null|\Request

getResponse()

Retrieve the MVC response object

Returns: null|\Response

getResult()

Retrieve the result of rendering

Returns: mixed

getTarget()

Get the event target

This may be either an object, or the name of a static method.

Returns: string|object

propagationIsStopped()

Is propagation stopped?

Returns: bool

setModel()

Set the view model

Parameter Name Type Description
$model \Model

Returns: \ViewEvent

setName()

Set the event name

Parameter Name Type Description
$name string

Returns:

setParam()

Set an individual event parameter

Parameter Name Type Description
$name string
$value mixed

Returns: \ViewEvent

setParams()

Set event parameters

Parameter Name Type Description
$params array|object|\ArrayAccess

Returns: \ViewEvent

setRenderer()

Set value for renderer

Parameter Name Type Description
$renderer \Renderer

Returns: \ViewEvent

setRequest()

Set the MVC request object

Parameter Name Type Description
$request \Request

Returns: \ViewEvent

setResponse()

Set the MVC response object

Parameter Name Type Description
$response \Response

Returns: \ViewEvent

setResult()

Set result of rendering

Parameter Name Type Description
$result mixed

Returns: \ViewEvent

setTarget()

Set the event target/context

Parameter Name Type Description
$target null|string|object

Returns:

stopPropagation()

Stop further event propagation

Parameter Name Type Description
$flag bool

Returns:

Top