You are here

interface SitemapInterface in Sitemap 2.0.x

Same name and namespace in other branches
  1. 8.2 src/SitemapInterface.php \Drupal\sitemap\SitemapInterface

Interface definition for sitemap plugins.

Hierarchy

Expanded class hierarchy of SitemapInterface

All classes that implement SitemapInterface

File

src/SitemapInterface.php, line 15

Namespace

Drupal\sitemap
View source
interface SitemapInterface extends ConfigurableInterface, DependentPluginInterface, PluginInspectionInterface {

  /**
   * Returns a form to configure settings for the mapping.
   *
   * @param array $form
   *   The form where the settings form is being included in.
   * @param \Drupal\Core\Form\FormStateInterface $form_state
   *   The current state of the form.
   *
   * @return array
   *   The form elements for the sitemap_map's settings.
   */
  public function settingsForm(array $form, FormStateInterface $form_state);

  /**
   * Returns a short summary for the current mapping settings.
   *
   * If an empty result is returned, a UI can still be provided to display
   * a settings form in case the mapping has configurable settings.
   *
   * @return string[]
   *   A short summary of the mapping settings.
   */
  public function settingsSummary();

  /**
   * Builds a renderable array for a sitemap item.
   *
   * @return array
   *   A renderable array for a themed field with its label and all its values.
   */
  public function view();

  /**
   * Returns the administrative label for this mapping plugin.
   *
   * @return string
   *   The label.
   */
  public function getLabel();

  /**
   * Returns the administrative description for this mapping plugin.
   *
   * @return string
   *   The description.
   */
  public function getDescription();

}

Members

Namesort descending Modifiers Type Description Overrides
ConfigurableInterface::defaultConfiguration public function Gets default configuration for this plugin. 14
ConfigurableInterface::getConfiguration public function Gets this plugin's configuration. 15
ConfigurableInterface::setConfiguration public function Sets the configuration for this plugin instance. 15
DependentPluginInterface::calculateDependencies public function Calculates dependencies for the configured plugin. 20
PluginInspectionInterface::getPluginDefinition public function Gets the definition of the plugin implementation. 4
PluginInspectionInterface::getPluginId public function Gets the plugin_id of the plugin instance. 2
SitemapInterface::getDescription public function Returns the administrative description for this mapping plugin. 1
SitemapInterface::getLabel public function Returns the administrative label for this mapping plugin. 1
SitemapInterface::settingsForm public function Returns a form to configure settings for the mapping. 1
SitemapInterface::settingsSummary public function Returns a short summary for the current mapping settings. 1
SitemapInterface::view public function Builds a renderable array for a sitemap item. 4