interface PostSaveViewInterface

Provides an interface for views plugins.

Hierarchy

Expanded class hierarchy of PostSaveViewInterface

All classes that implement PostSaveViewInterface

4 files declare their use of PostSaveViewInterface
Block.php in core/modules/views/src/Plugin/views/display/Block.php
PathPluginBase.php in core/modules/views/src/Plugin/views/display/PathPluginBase.php
Serializer.php in core/modules/rest/src/Plugin/views/style/Serializer.php
View.php in core/modules/views/src/Entity/View.php

File

core/modules/views/src/PostSaveViewInterface.php, line 10

Namespace

Drupal\views
View source
interface PostSaveViewInterface {
  
  /**
   * Acts on a saved view.
   *
   * @param \Drupal\views\PostSaveProcess $postSaveProcess
   *   The views save context. Plugins flag work here instead of performing
   *   it directly, so it happens at most once per view save. For example,
   *   the block plugin queues the block plugin manager via
   *   ::addDiscoveryToClear() even if more than one block display changed.
   * @param \Drupal\views\Plugin\views\display\DisplayPluginInterface|null $original_display
   *   (optional) The original display. Empty when saving a new view.
   *
   * @see \Drupal\views\Entity\View::postSave()
   */
  public function postSaveView(PostSaveProcess $postSaveProcess, ?DisplayPluginInterface $original_display = NULL) : void;

}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.