You are here

interface ViewsBulkOperationsViewDataInterface in Views Bulk Operations (VBO) 8

Same name and namespace in other branches
  1. 8.3 src/Service/ViewsBulkOperationsViewDataInterface.php \Drupal\views_bulk_operations\Service\ViewsBulkOperationsViewDataInterface
  2. 8.2 src/Service/ViewsBulkOperationsViewDataInterface.php \Drupal\views_bulk_operations\Service\ViewsBulkOperationsViewDataInterface
  3. 4.0.x src/Service/ViewsBulkOperationsViewDataInterface.php \Drupal\views_bulk_operations\Service\ViewsBulkOperationsViewDataInterface

Defines view data service for Views Bulk Operations.

Hierarchy

Expanded class hierarchy of ViewsBulkOperationsViewDataInterface

All classes that implement ViewsBulkOperationsViewDataInterface

1 file declares its use of ViewsBulkOperationsViewDataInterface
ViewsBulkOperationsEventSubscriber.php in src/EventSubscriber/ViewsBulkOperationsEventSubscriber.php

File

src/Service/ViewsBulkOperationsViewDataInterface.php, line 12

Namespace

Drupal\views_bulk_operations\Service
View source
interface ViewsBulkOperationsViewDataInterface {

  /**
   * Initialize additional variables.
   *
   * @param \Drupal\views\ViewExecutable $view
   *   The view object.
   * @param \Drupal\views\Plugin\views\display\DisplayPluginBase $display
   *   The current display plugin.
   * @param string $relationship
   *   Relationship ID.
   */
  public function init(ViewExecutable $view, DisplayPluginBase $display, $relationship);

  /**
   * Get entity type IDs.
   *
   * @return array
   *   Array of entity type IDs.
   */
  public function getEntityTypeIds();

  /**
   * Get view provider.
   *
   * @return string
   *   View provider ID.
   */
  public function getViewProvider();

  /**
   * Get entity from views row.
   *
   * @param \Drupal\views\ResultRow $row
   *   Views row object.
   *
   * @return \Drupal\Core\Entity\EntityInterface
   *   An entity object.
   */
  public function getEntity(ResultRow $row);

  /**
   * Get the total count of results on all pages.
   *
   * @return int
   *   The total number of results this view displays.
   */
  public function getTotalResults();

  /**
   * The default entity getter function.
   *
   * Must work well with standard Drupal core entity views.
   *
   * @param \Drupal\views\ResultRow $row
   *   Views result row.
   * @param string $relationship_id
   *   Id of the view relationship.
   * @param \Drupal\views\ViewExecutable $view
   *   The current view object.
   *
   * @return \Drupal\Core\Entity\FieldableEntityInterface
   *   The translated entity.
   */
  public function getEntityDefault(ResultRow $row, $relationship_id, ViewExecutable $view);

}

Members

Namesort descending Modifiers Type Description Overrides
ViewsBulkOperationsViewDataInterface::getEntity public function Get entity from views row. 1
ViewsBulkOperationsViewDataInterface::getEntityDefault public function The default entity getter function. 1
ViewsBulkOperationsViewDataInterface::getEntityTypeIds public function Get entity type IDs. 1
ViewsBulkOperationsViewDataInterface::getTotalResults public function Get the total count of results on all pages. 1
ViewsBulkOperationsViewDataInterface::getViewProvider public function Get view provider. 1
ViewsBulkOperationsViewDataInterface::init public function Initialize additional variables. 1