本文整理汇总了PHP中Drupal\Core\Form\ConfigFormBase::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP ConfigFormBase::__construct方法的具体用法?PHP ConfigFormBase::__construct怎么用?PHP ConfigFormBase::__construct使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Drupal\Core\Form\ConfigFormBase
的用法示例。
在下文中一共展示了ConfigFormBase::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
* Constructs a \Drupal\user\SharethisConfigurationForm object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
* The module handler.
* @param \Drupal\sharethis\SharethisManagerInterface $sharethis_manager
* The sharethis Manager.
*/
public function __construct(ConfigFactoryInterface $config_factory, ModuleHandlerInterface $module_handler, EntityManagerInterface $entity_manager, SharethisManagerInterface $sharethis_manager)
{
parent::__construct($config_factory);
$this->moduleHandler = $module_handler;
$this->entityManager = $entity_manager;
$this->sharethisManager = $sharethis_manager;
}
示例2: __construct
public function __construct(ConfigFactoryInterface $config_factory, StateInterface $state_interface, LinkGenerator $link_generator)
{
$this->config_factory = $config_factory;
$this->state_interface = $state_interface;
$this->link_generator = $link_generator;
parent::__construct($config_factory);
}
示例3: __construct
/**
* Constructs a \Drupal\system\ConfigFormBase object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* @param \Drupal\Core\StringTranslation\TranslationInterface $string_translation
* @param \Drupal\payment\Plugin\Payment\Method\PaymentMethodManagerInterface $payment_method_manager
* @param \Drupal\plugin\PluginType\PluginTypeInterface $plugin_selector_type
*/
public function __construct(ConfigFactoryInterface $config_factory, TranslationInterface $string_translation, PaymentMethodManagerInterface $payment_method_manager, PluginTypeInterface $plugin_selector_type)
{
parent::__construct($config_factory);
$this->paymentMethodManager = $payment_method_manager;
$this->pluginSelectorType = $plugin_selector_type;
$this->stringTranslation = $string_translation;
}
示例4: __construct
/**
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* @param Profiler $profiler
* @param \Drupal\webprofiler\Profiler\ProfilerStorageManager $storageManager
* @param array $templates
*/
public function __construct(ConfigFactoryInterface $config_factory, Profiler $profiler, ProfilerStorageManager $storageManager, $templates)
{
parent::__construct($config_factory);
$this->profiler = $profiler;
$this->templates = $templates;
$this->storageManager = $storageManager;
}
示例5: __construct
/**
* {@inheritdoc}
*/
public function __construct(ConfigFactoryInterface $config_factory, ExcludeNodeTitleManagerInterface $exclude_node_title_manager, EntityTypeBundleInfoInterface $entity_bundle_info, EntityDisplayRepositoryInterface $entity_display_repository)
{
parent::__construct($config_factory);
$this->excludeNodeTitleManager = $exclude_node_title_manager;
$this->bundleInfo = $entity_bundle_info;
$this->entityDisplayRepository = $entity_display_repository;
}
示例6: __construct
/**
* Constructs a CronForm object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\State\StateInterface $state
* The state key value store.
* @param \Drupal\Core\CronInterface $cron
* The cron service.
* @param \Drupal\Core\Datetime\DateFormatter $date_formatter
* The date formatter service.
*/
public function __construct(ConfigFactoryInterface $config_factory, StateInterface $state, CronInterface $cron, DateFormatter $date_formatter)
{
parent::__construct($config_factory);
$this->state = $state;
$this->cron = $cron;
$this->dateFormatter = $date_formatter;
}
示例7: __construct
/**
* Constructs a SiteInformationForm object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\Path\AliasManagerInterface $alias_manager
* The path alias manager.
* @param \Drupal\Core\Path\PathValidatorInterface $path_validator
* The path validator.
* @param \Drupal\Core\Routing\RequestContext $request_context
* The request context.
*/
public function __construct(ConfigFactoryInterface $config_factory, AliasManagerInterface $alias_manager, PathValidatorInterface $path_validator, RequestContext $request_context)
{
parent::__construct($config_factory);
$this->aliasManager = $alias_manager;
$this->pathValidator = $path_validator;
$this->requestContext = $request_context;
}
示例8: __construct
/**
* Constructs a \Drupal\disqus\DisqusSettingsForm object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
* The module handler.
* @param \Drupal\file\FileUsage\FileUsageInterface
* The file usage overridable.
* @param \Drupal\Core\Entity\EntityTypeManagerInterface
* The entity type manager.
*/
public function __construct(ConfigFactoryInterface $config_factory, ModuleHandlerInterface $module_handler, FileUsageInterface $file_usage, EntityTypeManagerInterface $entity_type_manager)
{
parent::__construct($config_factory);
$this->moduleHandler = $module_handler;
$this->fileUsage = $file_usage;
$this->entityTypeManager = $entity_type_manager;
}
示例9: __construct
/**
* Constructs a new XmlSitemapSettingsForm object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\State\StateInterface $state
* The state service.
* @param \Drupal\Core\Datetime\DateFormatter $date
* The date formatter service.
* @param \Drupal\xmlsitemap\XmlSitemapLinkStorageInterface $link_storage
* The xmlsitemap link storage service.
*/
public function __construct(ConfigFactoryInterface $config_factory, StateInterface $state, DateFormatter $date, XmlSitemapLinkStorageInterface $link_storage)
{
parent::__construct($config_factory);
$this->state = $state;
$this->date = $date;
$this->linkStorage = $link_storage;
}
示例10: __construct
/**
* Constructs a ThemeSettingsForm object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
* The module handler instance to use.
* @param \Drupal\Core\Extension\ThemeHandlerInterface $theme_handler
* The theme handler.
* @param \Symfony\Component\HttpFoundation\File\MimeType\MimeTypeGuesserInterface $mime_type_guesser
* The MIME type guesser instance to use.
*/
public function __construct(ConfigFactoryInterface $config_factory, ModuleHandlerInterface $module_handler, ThemeHandlerInterface $theme_handler, MimeTypeGuesserInterface $mime_type_guesser)
{
parent::__construct($config_factory);
$this->moduleHandler = $module_handler;
$this->themeHandler = $theme_handler;
$this->mimeTypeGuesser = $mime_type_guesser;
}
示例11: __construct
/**
* Constructs a \Drupal\aggregator\SettingsForm object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
* The module handler.
* @param \Drupal\Core\PrivateKey $private_key
* The private key.
* @param \Drupal\acquia_connector\Client $client
* The Acquia client.
*/
public function __construct(ConfigFactoryInterface $config_factory, ModuleHandlerInterface $module_handler, PrivateKey $private_key, Client $client)
{
parent::__construct($config_factory);
$this->moduleHandler = $module_handler;
$this->privateKey = $private_key;
$this->client = $client;
}
示例12: __construct
/**
* Constructs a \Drupal\system\CustomFieldFormBase object.
*
* @param \Drupal\Core\Config\ConfigFactory $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\Entity\EntityTypeManager
* The entity type manager.
* @param \Drupal\Core\Cache\CacheTagsInvalidatorInterface
* The cache invalidator.
* @param \Drupal\Core\Extension\ModuleHandler
* The module handler.
*/
public function __construct(ConfigFactory $config_factory, EntityTypeManagerInterface $entity_type_manager, CacheTagsInvalidatorInterface $cache_invalidator, ModuleHandler $module_handler)
{
parent::__construct($config_factory);
$this->entityTypeManager = $entity_type_manager;
$this->cacheInvalidator = $cache_invalidator;
$this->moduleHandler = $module_handler;
}
示例13: __construct
/**
* Constructs a \Drupal\system\ConfigFormBase object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
*/
public function __construct(ConfigFactoryInterface $config_factory, MailsystemManager $mail_manager, ModuleHandlerInterface $module_handler, ThemeHandlerInterface $theme_handler)
{
parent::__construct($config_factory);
$this->mailManager = $mail_manager;
$this->moduleHandler = $module_handler;
$this->themeHandler = $theme_handler;
}
示例14: __construct
/**
* Constructs a ImageToolkitForm object.
*
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
* The factory for configuration objects.
* @param \Drupal\Core\ImageToolkit\ImageToolkitManager $manager
* The image toolkit plugin manager.
*/
public function __construct(ConfigFactoryInterface $config_factory, ImageToolkitManager $manager)
{
parent::__construct($config_factory);
foreach ($manager->getAvailableToolkits() as $id => $definition) {
$this->availableToolkits[$id] = $manager->createInstance($id);
}
}
示例15: __construct
/**
* {@inheritDoc}
*/
public function __construct(ConfigFactoryInterface $config_factory, EntityTypeManagerInterface $entity_type_manager, EntityFieldManagerInterface $entity_field_manager, AliasTypeManager $alias_type_manager)
{
parent::__construct($config_factory);
$this->entityTypeManager = $entity_type_manager;
$this->entityFieldManager = $entity_field_manager;
$this->aliasTypeManager = $alias_type_manager;
}