You are here

interface ViewModeConfigInterface in Search API Pages 8

Hierarchy

Expanded class hierarchy of ViewModeConfigInterface

All classes that implement ViewModeConfigInterface

File

src/Config/ViewModeConfigInterface.php, line 5

Namespace

Drupal\search_api_page\Config
View source
interface ViewModeConfigInterface {

  /**
   * Gets the configured view mode for a given data source and bundle.
   *
   * @param string $dataSourceId
   *   The data source id.
   * @param string $bundleId
   *   The bundle id.
   *
   * @return string
   *   The view mode machine name.
   */
  public function getViewMode($dataSourceId, $bundleId);

  /**
   * Gets the default view mode for a given data source.
   *
   * @param string $dataSourceId
   *   The data source id.
   *
   * @return string
   *   The view mode machine name.
   */
  public function getDefaultViewMode($dataSourceId);

  /**
   * Determines if the given data source has any view mode overrides.
   *
   * @param string $dataSourceId
   *   The data source id.
   *
   * @return bool
   *   True if any overrides are present, false if there are not.
   */
  public function hasOverrides($dataSourceId);

  /**
   * Determines if a view mode is overridden for a given data source and bundle.
   *
   * @param string $dataSourceId
   *   The data source id.
   * @param string $bundleId
   *   The bundle id.
   *
   * @return bool
   *   True if the bundle is overridden, false if it is not.
   */
  public function isOverridden($dataSourceId, $bundleId);

}

Members

Namesort descending Modifiers Type Description Overrides
ViewModeConfigInterface::getDefaultViewMode public function Gets the default view mode for a given data source. 1
ViewModeConfigInterface::getViewMode public function Gets the configured view mode for a given data source and bundle. 1
ViewModeConfigInterface::hasOverrides public function Determines if the given data source has any view mode overrides. 1
ViewModeConfigInterface::isOverridden public function Determines if a view mode is overridden for a given data source and bundle. 1