AjaxResponseSubscriber::$ajaxResponseAttachmentsProcessor

The AJAX response attachments processor service. Type: \Drupal\Core\Render\AttachmentsResponseProcessorInterface File core/lib/Drupal/Core/EventSubscriber/AjaxResponseSubscriber.php, line 23 Class AjaxResponseSubscriber Response subscriber to handle AJAX responses. Namespace Drupal\Core\EventSubscriber Code protected $ajaxResponseAttachmentsProcessor;

AjaxResponseSubscriber

Response subscriber to handle AJAX responses. Hierarchy class \Drupal\Core\EventSubscriber\AjaxResponseSubscriber implements EventSubscriberInterface File core/lib/Drupal/Core/EventSubscriber/AjaxResponseSubscriber.php, line 16 Namespace Drupal\Core\EventSubscriber Members Name Modifiers Type Description AjaxResponseSubscriber::$ajaxResponseAttachmentsProcessor protected property The AJAX response attachments processor service. AjaxResponseSubscriber::AJAX_REQUEST_PARA

AjaxResponseAttachmentsProcessor::__construct

public AjaxResponseAttachmentsProcessor::__construct(AssetResolverInterface $asset_resolver, ConfigFactoryInterface $config_factory, AssetCollectionRendererInterface $css_collection_renderer, AssetCollectionRendererInterface $js_collection_renderer, RequestStack $request_stack, RendererInterface $renderer, ModuleHandlerInterface $module_handler) Constructs a AjaxResponseAttachmentsProcessor object. Parameters \Drupal\Core\Asset\AssetResolverInterface $asset_resolver: An asset resolver. \Drupal

AjaxResponseAttachmentsProcessor::processAttachments

public AjaxResponseAttachmentsProcessor::processAttachments(AttachmentsInterface $response) Processes the attachments of a response that has attachments. Libraries, JavaScript settings, feeds, HTML <head> tags, HTML <head> links, HTTP headers, and the HTTP status code are attached to render arrays using the #attached property. The #attached property is an associative array, where the keys are the attachment types and the values are the attached data. For example: $build['#attached']

AjaxResponseAttachmentsProcessor::buildAttachmentsCommands

protected AjaxResponseAttachmentsProcessor::buildAttachmentsCommands(AjaxResponse $response, Request $request) Prepares the AJAX commands to attach assets. Parameters \Drupal\Core\Ajax\AjaxResponse $response: The AJAX response to update. \Symfony\Component\HttpFoundation\Request $request: The request object that the AJAX is responding to. Return value array An array of commands ready to be returned as JSON. File core/lib/Drupal/Core/Ajax/AjaxResponseAttachmentsProcessor.php, line 130 Class

AjaxResponseAttachmentsProcessor::$requestStack

The request stack. Type: \Symfony\Component\HttpFoundation\RequestStack File core/lib/Drupal/Core/Ajax/AjaxResponseAttachmentsProcessor.php, line 57 Class AjaxResponseAttachmentsProcessor Processes attachments of AJAX responses. Namespace Drupal\Core\Ajax Code protected $requestStack;

AjaxResponseAttachmentsProcessor::$renderer

The renderer. Type: \Drupal\Core\Render\RendererInterface File core/lib/Drupal/Core/Ajax/AjaxResponseAttachmentsProcessor.php, line 64 Class AjaxResponseAttachmentsProcessor Processes attachments of AJAX responses. Namespace Drupal\Core\Ajax Code protected $renderer;

AjaxResponseAttachmentsProcessor::$moduleHandler

The module handler. Type: \Drupal\Core\Extension\ModuleHandlerInterface File core/lib/Drupal/Core/Ajax/AjaxResponseAttachmentsProcessor.php, line 71 Class AjaxResponseAttachmentsProcessor Processes attachments of AJAX responses. Namespace Drupal\Core\Ajax Code protected $moduleHandler;

AjaxResponseAttachmentsProcessor::$jsCollectionRenderer

The JS asset collection renderer service. Type: \Drupal\Core\Asset\AssetCollectionRendererInterface File core/lib/Drupal/Core/Ajax/AjaxResponseAttachmentsProcessor.php, line 50 Class AjaxResponseAttachmentsProcessor Processes attachments of AJAX responses. Namespace Drupal\Core\Ajax Code protected $jsCollectionRenderer;

AjaxResponseAttachmentsProcessor::$cssCollectionRenderer

The CSS asset collection renderer service. Type: \Drupal\Core\Asset\AssetCollectionRendererInterface File core/lib/Drupal/Core/Ajax/AjaxResponseAttachmentsProcessor.php, line 43 Class AjaxResponseAttachmentsProcessor Processes attachments of AJAX responses. Namespace Drupal\Core\Ajax Code protected $cssCollectionRenderer;