YamlFileLoader::validate

private YamlFileLoader::validate($content, $file) Validates a YAML file. Parameters mixed $content: string $file: Return value array Throws InvalidArgumentException When service file is not valid. File core/lib/Drupal/Core/DependencyInjection/YamlFileLoader.php, line 357 Class YamlFileLoader YamlFileLoader loads YAML files service definitions. Namespace Drupal\Core\DependencyInjection Code private function validate($content, $file) { if (null === $content) { return $content;

YamlFileLoader::parseDefinitions

private YamlFileLoader::parseDefinitions($content, $file) Parses definitions Parameters array $content: string $file: File core/lib/Drupal/Core/DependencyInjection/YamlFileLoader.php, line 104 Class YamlFileLoader YamlFileLoader loads YAML files service definitions. Namespace Drupal\Core\DependencyInjection Code private function parseDefinitions($content, $file) { if (!isset($content['services'])) { return; } if (!is_array($content['services'])) { throw new InvalidArg

YamlFileLoader::resolveServices

private YamlFileLoader::resolveServices($value) Resolves services. Parameters string|array $value: Return value array|string|Reference File core/lib/Drupal/Core/DependencyInjection/YamlFileLoader.php, line 381 Class YamlFileLoader YamlFileLoader loads YAML files service definitions. Namespace Drupal\Core\DependencyInjection Code private function resolveServices($value) { if (is_array($value)) { $value = array_map(array($this, 'resolveServices'), $value); } elseif (is_stri

YamlFileLoader::__construct

public YamlFileLoader::__construct(ContainerBuilder $container) File core/lib/Drupal/Core/DependencyInjection/YamlFileLoader.php, line 46 Class YamlFileLoader YamlFileLoader loads YAML files service definitions. Namespace Drupal\Core\DependencyInjection Code public function __construct(ContainerBuilder $container) { $this->container = $container; $this->fileCache = FileCacheFactory::get('container_yaml_loader'); }

YamlPecl

Provides default serialization for YAML using the PECL extension. Hierarchy class \Drupal\Component\Serialization\YamlPecl implements SerializationInterface File core/lib/Drupal/Component/Serialization/YamlPecl.php, line 10 Namespace Drupal\Component\Serialization Members Name Modifiers Type Description YamlPecl::applyBooleanCallbacks public static function Applies callbacks after parsing to ignore 1.1 style booleans. YamlPecl::decode public static function Decod

YamlPecl::applyBooleanCallbacks

public static YamlPecl::applyBooleanCallbacks($value, $tag, $flags) Applies callbacks after parsing to ignore 1.1 style booleans. Parameters mixed $value: Value from YAML file. string $tag: Tag that triggered the callback. int $flags: Scalar entity style flags. Return value string|bool FALSE, false, TRUE and true are returned as booleans, everything else is returned as a string. File core/lib/Drupal/Component/Serialization/YamlPecl.php, line 87 Class YamlPecl Provides default serializati

YamlFileLoader::loadFile

protected YamlFileLoader::loadFile($file) Loads a YAML file. Parameters string $file: Return value array The file content Throws InvalidArgumentException When the given file is not a local file or when it does not exist. File core/lib/Drupal/Core/DependencyInjection/YamlFileLoader.php, line 333 Class YamlFileLoader YamlFileLoader loads YAML files service definitions. Namespace Drupal\Core\DependencyInjection Code protected function loadFile($file) { if (!stream_is_local($file))

YamlFileLoader::$fileCache

File cache object. Type: \Drupal\Component\FileCache\FileCacheInterface File core/lib/Drupal/Core/DependencyInjection/YamlFileLoader.php, line 43 Class YamlFileLoader YamlFileLoader loads YAML files service definitions. Namespace Drupal\Core\DependencyInjection Code protected $fileCache;

YamlFileLoader::parseDefinition

private YamlFileLoader::parseDefinition($id, $service, $file) Parses a definition. Parameters string $id: array $service: string $file: Throws InvalidArgumentException When tags are invalid. File core/lib/Drupal/Core/DependencyInjection/YamlFileLoader.php, line 138 Class YamlFileLoader YamlFileLoader loads YAML files service definitions. Namespace Drupal\Core\DependencyInjection Code private function parseDefinition($id, $service, $file) { if (is_string($service) && 0 ===

YamlFileLoader::load

public YamlFileLoader::load($file) Loads a Yaml file. Parameters mixed $file: The resource File core/lib/Drupal/Core/DependencyInjection/YamlFileLoader.php, line 58 Class YamlFileLoader YamlFileLoader loads YAML files service definitions. Namespace Drupal\Core\DependencyInjection Code public function load($file) { // Load from the file cache, fall back to loading the file. $content = $this->fileCache->get($file); if (!$content) { $content = $this->loadFile($file);