AbstractWidgetViewHelper
abstract class AbstractWidgetViewHelper extends AbstractViewHelper implements ChildNodeAccessInterface (View source)
Properties
protected RenderingContextInterface | $renderingContext | from AbstractViewHelper | |
protected ControllerContext | $controllerContext | Controller Context to use |
from AbstractViewHelper |
protected ObjectManagerInterface | $objectManager | from AbstractViewHelper | |
protected LoggerInterface | $logger | from AbstractViewHelper | |
protected bool | $escapeOutput | ||
protected AbstractWidgetController | $controller | The Controller associated to this widget. |
|
protected bool | $ajaxWidget | If set to true, it is an AJAX widget. |
|
protected bool | $storeConfigurationInSession | If set to false, this widget won't create a session (only relevant for AJAX widgets). |
Methods
No description
Injects the (system) logger based on PSR-3.
Registers the widgetId viewhelper
Initialize the arguments of the ViewHelper, and call the render() method of the ViewHelper.
Stores the syntax tree child nodes in the Widget Context, so they can be
rendered with
Generate the configuration for this widget. Override to adjust.
Generate the configuration for this widget in AJAX context.
Generate the configuration for this widget in non-AJAX context.
Initiate a sub request to $this->controller. Make sure to fill $this->controller via Dependency Injection.
Resets the ViewHelper state by creating a fresh WidgetContext
No description
Details
void
setRenderingContext(RenderingContextInterface $renderingContext)
No description
void
injectObjectManager(ObjectManagerInterface $objectManager)
No description
void
injectLogger(LoggerInterface $logger)
Injects the (system) logger based on PSR-3.
bool
isEscapingInterceptorEnabled()
No description
void
injectAjaxWidgetContextHolder(AjaxWidgetContextHolder $ajaxWidgetContextHolder)
No description
void
injectWidgetContext(WidgetContext $widgetContext)
No description
void
initializeArguments()
Registers the widgetId viewhelper
string
initializeArgumentsAndRender()
Initialize the arguments of the ViewHelper, and call the render() method of the ViewHelper.
void
setChildNodes(array $childNodes)
Stores the syntax tree child nodes in the Widget Context, so they can be
rendered with
protected array
getWidgetConfiguration()
Generate the configuration for this widget. Override to adjust.
protected array
getAjaxWidgetConfiguration()
Generate the configuration for this widget in AJAX context.
By default, returns getWidgetConfiguration(). Should become API later.
protected array
getNonAjaxWidgetConfiguration()
Generate the configuration for this widget in non-AJAX context.
By default, returns getWidgetConfiguration(). Should become API later.
protected string
initiateSubRequest()
Initiate a sub request to $this->controller. Make sure to fill $this->controller via Dependency Injection.
void
resetState()
Resets the ViewHelper state by creating a fresh WidgetContext
string
compile(string $argumentsName, string $closureName, string $initializationPhpCode, ViewHelperNode $node, TemplateCompiler $compiler)
No description