You are here

trait BlazyFormatterTrait in Blazy 7

Same name and namespace in other branches
  1. 8.2 src/Plugin/Field/FieldFormatter/BlazyFormatterTrait.php \Drupal\blazy\Plugin\Field\FieldFormatter\BlazyFormatterTrait
  2. 8 src/Plugin/Field/FieldFormatter/BlazyFormatterTrait.php \Drupal\blazy\Plugin\Field\FieldFormatter\BlazyFormatterTrait

A Trait common for blazy formatters.

Hierarchy

File

src/Plugin/Field/FieldFormatter/BlazyFormatterTrait.php, line 8

Namespace

Drupal\blazy\Plugin\Field\FieldFormatter
View source
trait BlazyFormatterTrait {

  /**
   * The blazy-related formatter service.
   *
   * @var \Drupal\blazy\BlazyFormatter
   */
  protected $formatter;

  /**
   * The blazy field formatter manager.
   *
   * @var \Drupal\blazy\BlazyManagerInterface
   */
  protected $manager;

  /**
   * Returns the blazy-related formatter.
   */
  public function formatter() {
    return $this->formatter;
  }

  /**
   * Returns the blazy service.
   */
  public function manager() {
    return $this->manager;
  }

  /**
   * {@inheritdoc}
   */
  public function settingsSummary(array $definition) {
    return $this
      ->admin()
      ->getSettingsSummary($definition);
  }

}

Members

Namesort descending Modifiers Type Description Overrides
BlazyFormatterTrait::$formatter protected property The blazy-related formatter service.
BlazyFormatterTrait::$manager protected property The blazy field formatter manager.
BlazyFormatterTrait::formatter public function Returns the blazy-related formatter.
BlazyFormatterTrait::manager public function Returns the blazy service.
BlazyFormatterTrait::settingsSummary public function