Yaml::getSerializer

protected static Yaml::getSerializer()

Determines which implementation to use for parsing YAML.

Overrides Yaml::getSerializer

File

core/lib/Drupal/Core/Serialization/Yaml.php, line 18

Class

Yaml
Provides a YAML serialization implementation.

Namespace

Drupal\Core\Serialization

Code

protected static function getSerializer() {
  // Allow settings.php to override the YAML serializer.
  if (!isset(static::$serializer) && 
    $class = Settings::get('yaml_parser_class')) {

    static::$serializer = $class;
  }
  return parent::getSerializer();
}
doc_Drupal
2016-10-29 09:56:54
Comments
Leave a Comment

Please login to continue.