
| Current Path : /var/www/html/rocksensor1/web/core/modules/system/tests/modules/new_dependency_test/src/ |
Linux ift1.ift-informatik.de 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64 |
| Current File : /var/www/html/rocksensor1/web/core/modules/system/tests/modules/new_dependency_test/src/Service.php |
<?php
namespace Drupal\new_dependency_test;
/**
* A service that can decorated itself.
*
* @see new_dependency_test.services.yml
*/
class Service {
/**
* The decorated service.
*
* @var \Drupal\new_dependency_test\Service
*/
protected $inner;
/**
* Service constructor.
*
* @param \Drupal\new_dependency_test\Service|null $inner
* The service to decorate.
*/
public function __construct(?Service $inner = NULL) {
$this->inner = $inner;
}
/**
* Determines if the service is decorated.
*
* @return bool
* TRUE if the services is decorated, FALSE if not.
*/
public function isDecorated() {
return isset($this->inner);
}
}