og-8.x-1.x-dev/src/OgFieldsPluginManager.php

src/OgFieldsPluginManager.php
<?php

declare(strict_types=1);

namespace Drupal\og;

use Drupal\Core\Cache\CacheBackendInterface;
use Drupal\Core\Extension\ModuleHandlerInterface;
use Drupal\Core\Plugin\DefaultPluginManager;
use Drupal\og\Attribute\OgFields;

/**
 * Manages OG fields plugins.
 */
class OgFieldsPluginManager extends DefaultPluginManager {

  public function __construct(\Traversable $namespaces, CacheBackendInterface $cache_backend, ModuleHandlerInterface $module_handler) {
    parent::__construct(
      'Plugin/OgFields',
      $namespaces,
      $module_handler,
      OgFieldsInterface::class,
      OgFields::class,
      'Drupal\og\Annotation\OgFields',
    );
    $this->alterInfo('og_fields_alter');
    $this->setCacheBackend($cache_backend, 'og_fields');
  }

}

Главная | Обратная связь

drupal hosting | друпал хостинг | it patrol .inc