PHP Класс Neos\FluidAdaptor\Core\Widget\AbstractWidgetViewHelper

Наследование: extends Neos\FluidAdaptor\Core\ViewHelper\AbstractViewHelper, implements Neos\FluidAdaptor\Core\ViewHelper\Facets\ChildNodeAccessInterface
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$ajaxWidget boolean If set to TRUE, it is an AJAX widget.
$controller AbstractWidgetController This needs to be filled by the individual subclass using property injection.
$escapeOutput boolean
$storeConfigurationInSession boolean You then need to manually add the serialized configuration data to your links, by setting "includeWidgetContext" to TRUE in the widget link and URI ViewHelpers.

Открытые методы

Метод Описание
compile ( string $argumentsName, string $closureName, string &$initializationPhpCode, TYPO3Fluid\Fluid\Core\Parser\SyntaxTree\ViewHelperNode $node, TYPO3Fluid\Fluid\Core\Compiler\TemplateCompiler $compiler ) : string
initializeArguments ( ) : void Registers the widgetId viewhelper
initializeArgumentsAndRender ( ) : string Initialize the arguments of the ViewHelper, and call the render() method of the ViewHelper.
injectAjaxWidgetContextHolder ( AjaxWidgetContextHolder $ajaxWidgetContextHolder ) : void
injectWidgetContext ( WidgetContext $widgetContext ) : void
resetState ( ) : void Resets the ViewHelper state by creating a fresh WidgetContext
setChildNodes ( array $childNodes ) : void Stores the syntax tree child nodes in the Widget Context, so they can be rendered with lateron.

Защищенные методы

Метод Описание
getAjaxWidgetConfiguration ( ) : array Generate the configuration for this widget in AJAX context.
getNonAjaxWidgetConfiguration ( ) : array Generate the configuration for this widget in non-AJAX context.
getWidgetConfiguration ( ) : array Generate the configuration for this widget. Override to adjust.
initiateSubRequest ( ) : Response Initiate a sub request to $this->controller. Make sure to fill $this->controller via Dependency Injection.

Приватные методы

Метод Описание
initializeWidgetContext ( ) : void Initialize the Widget Context, before the Render method is called.
initializeWidgetIdentifier ( ) : void The widget identifier is unique on the current page, and is used in the URI as a namespace for the widget's arguments.
passArgumentsToSubRequest ( ActionRequest $subRequest ) : void Pass the arguments of the widget to the sub request.

Описание методов

compile() публичный Метод

public compile ( string $argumentsName, string $closureName, string &$initializationPhpCode, TYPO3Fluid\Fluid\Core\Parser\SyntaxTree\ViewHelperNode $node, TYPO3Fluid\Fluid\Core\Compiler\TemplateCompiler $compiler ) : string
$argumentsName string
$closureName string
$initializationPhpCode string
$node TYPO3Fluid\Fluid\Core\Parser\SyntaxTree\ViewHelperNode
$compiler TYPO3Fluid\Fluid\Core\Compiler\TemplateCompiler
Результат string

getAjaxWidgetConfiguration() защищенный Метод

By default, returns getWidgetConfiguration(). Should become API later.
protected getAjaxWidgetConfiguration ( ) : array
Результат array

getNonAjaxWidgetConfiguration() защищенный Метод

By default, returns getWidgetConfiguration(). Should become API later.
protected getNonAjaxWidgetConfiguration ( ) : array
Результат array

getWidgetConfiguration() защищенный Метод

Generate the configuration for this widget. Override to adjust.
protected getWidgetConfiguration ( ) : array
Результат array

initializeArguments() публичный Метод

Registers the widgetId viewhelper
public initializeArguments ( ) : void
Результат void

initializeArgumentsAndRender() публичный Метод

Initialize the arguments of the ViewHelper, and call the render() method of the ViewHelper.
public initializeArgumentsAndRender ( ) : string
Результат string the rendered ViewHelper.

initiateSubRequest() защищенный Метод

Initiate a sub request to $this->controller. Make sure to fill $this->controller via Dependency Injection.
protected initiateSubRequest ( ) : Response
Результат Neos\Flow\Http\Response the response of this request.

injectAjaxWidgetContextHolder() публичный Метод

public injectAjaxWidgetContextHolder ( AjaxWidgetContextHolder $ajaxWidgetContextHolder ) : void
$ajaxWidgetContextHolder AjaxWidgetContextHolder
Результат void

injectWidgetContext() публичный Метод

public injectWidgetContext ( WidgetContext $widgetContext ) : void
$widgetContext WidgetContext
Результат void

resetState() публичный Метод

Resets the ViewHelper state by creating a fresh WidgetContext
public resetState ( ) : void
Результат void

setChildNodes() публичный Метод

Stores the syntax tree child nodes in the Widget Context, so they can be rendered with lateron.
public setChildNodes ( array $childNodes ) : void
$childNodes array The SyntaxTree Child nodes of this ViewHelper.
Результат void

Описание свойств

$ajaxWidget защищенное свойство

If set to TRUE, it is an AJAX widget.
protected bool $ajaxWidget
Результат boolean

$controller защищенное свойство

This needs to be filled by the individual subclass using property injection.
protected AbstractWidgetController,Neos\FluidAdaptor\Core\Widget $controller
Результат AbstractWidgetController

$escapeOutput защищенное свойство

protected bool $escapeOutput
Результат boolean

$storeConfigurationInSession защищенное свойство

You then need to manually add the serialized configuration data to your links, by setting "includeWidgetContext" to TRUE in the widget link and URI ViewHelpers.
protected bool $storeConfigurationInSession
Результат boolean