class FieldModuleUninstallValidator in Zircon Profile 8
Same name in this branch
- 8 core/lib/Drupal/Core/Field/FieldModuleUninstallValidator.php \Drupal\Core\Field\FieldModuleUninstallValidator
- 8 core/lib/Drupal/Core/ProxyClass/Field/FieldModuleUninstallValidator.php \Drupal\Core\ProxyClass\Field\FieldModuleUninstallValidator
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/ProxyClass/Field/FieldModuleUninstallValidator.php \Drupal\Core\ProxyClass\Field\FieldModuleUninstallValidator
Provides a proxy class for \Drupal\Core\Field\FieldModuleUninstallValidator.
Hierarchy
- class \Drupal\Core\ProxyClass\Field\FieldModuleUninstallValidator implements ModuleUninstallValidatorInterface uses DependencySerializationTrait
Expanded class hierarchy of FieldModuleUninstallValidator
See also
\Drupal\Component\ProxyBuilder
File
- core/
lib/ Drupal/ Core/ ProxyClass/ Field/ FieldModuleUninstallValidator.php, line 19 - Contains \Drupal\Core\ProxyClass\Field\FieldModuleUninstallValidator.
Namespace
Drupal\Core\ProxyClass\FieldView source
class FieldModuleUninstallValidator implements \Drupal\Core\Extension\ModuleUninstallValidatorInterface {
use \Drupal\Core\DependencyInjection\DependencySerializationTrait;
/**
* The id of the original proxied service.
*
* @var string
*/
protected $drupalProxyOriginalServiceId;
/**
* The real proxied service, after it was lazy loaded.
*
* @var \Drupal\Core\Field\FieldModuleUninstallValidator
*/
protected $service;
/**
* The service container.
*
* @var \Symfony\Component\DependencyInjection\ContainerInterface
*/
protected $container;
/**
* Constructs a ProxyClass Drupal proxy object.
*
* @param \Symfony\Component\DependencyInjection\ContainerInterface $container
* The container.
* @param string $drupal_proxy_original_service_id
* The service ID of the original service.
*/
public function __construct(\Symfony\Component\DependencyInjection\ContainerInterface $container, $drupal_proxy_original_service_id) {
$this->container = $container;
$this->drupalProxyOriginalServiceId = $drupal_proxy_original_service_id;
}
/**
* Lazy loads the real service from the container.
*
* @return object
* Returns the constructed real service.
*/
protected function lazyLoadItself() {
if (!isset($this->service)) {
$this->service = $this->container
->get($this->drupalProxyOriginalServiceId);
}
return $this->service;
}
/**
* {@inheritdoc}
*/
public function validate($module_name) {
return $this
->lazyLoadItself()
->validate($module_name);
}
/**
* {@inheritdoc}
*/
public function setStringTranslation(\Drupal\Core\StringTranslation\TranslationInterface $translation) {
return $this
->lazyLoadItself()
->setStringTranslation($translation);
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
DependencySerializationTrait:: |
protected | property | An array of service IDs keyed by property name used for serialization. | |
DependencySerializationTrait:: |
public | function | 1 | |
DependencySerializationTrait:: |
public | function | 2 | |
FieldModuleUninstallValidator:: |
protected | property | The service container. | |
FieldModuleUninstallValidator:: |
protected | property | The id of the original proxied service. | |
FieldModuleUninstallValidator:: |
protected | property | The real proxied service, after it was lazy loaded. | |
FieldModuleUninstallValidator:: |
protected | function | Lazy loads the real service from the container. | |
FieldModuleUninstallValidator:: |
public | function | ||
FieldModuleUninstallValidator:: |
public | function |
Determines the reasons a module can not be uninstalled. Overrides ModuleUninstallValidatorInterface:: |
|
FieldModuleUninstallValidator:: |
public | function | Constructs a ProxyClass Drupal proxy object. |