You are here

interface SimpleAdsTypeInterface in SimpleAds 8

Defines an interface SimpleAdsType plugins.

Hierarchy

Expanded class hierarchy of SimpleAdsTypeInterface

All classes that implement SimpleAdsTypeInterface

File

src/SimpleAdsTypeInterface.php, line 11

Namespace

Drupal\simpleads
View source
interface SimpleAdsTypeInterface extends PluginInspectionInterface {

  /**
   * Return SimpleAds type name.
   *
   * @return string
   */
  public function getName();

  /**
   * Return ad form to create an ad.
   *
   * @return array form
   */
  public function buildForm(array $form, FormStateInterface $form_state, $type = NULL, $id = NULL);

  /**
   * Create an ad.
   */
  public function createFormSubmit($options, FormStateInterface $form_state, $type = NULL);

  /**
   * Update an ad.
   */
  public function updateFormSubmit($options, FormStateInterface $form_state, $type = NULL, $id = NULL);

  /**
   * Delete an ad.
   */
  public function deleteFormSubmit($options, FormStateInterface $form_state, $type = NULL, $id = NULL);

  /**
   * Theme function for the ad.
   *
   * @return array
   */
  public function theme();

  /**
   * Render an ad.
   *
   * @return string
   */
  public function render();

}

Members

Namesort descending Modifiers Type Description Overrides
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
SimpleAdsTypeInterface::buildForm public function Return ad form to create an ad. 1
SimpleAdsTypeInterface::createFormSubmit public function Create an ad. 1
SimpleAdsTypeInterface::deleteFormSubmit public function Delete an ad. 1
SimpleAdsTypeInterface::getName public function Return SimpleAds type name. 1
SimpleAdsTypeInterface::render public function Render an ad. 1
SimpleAdsTypeInterface::theme public function Theme function for the ad. 1
SimpleAdsTypeInterface::updateFormSubmit public function Update an ad. 1