You are here

class YamlParserProxy in Drupal 8

Same name in this branch
  1. 8 core/tests/Drupal/Tests/Core/Serialization/YamlTest.php \Drupal\Tests\Core\Serialization\YamlParserProxy
  2. 8 core/tests/Drupal/Tests/Component/Serialization/YamlTest.php \Drupal\Tests\Component\Serialization\YamlParserProxy
Same name and namespace in other branches
  1. 9 core/tests/Drupal/Tests/Core/Serialization/YamlTest.php \Drupal\Tests\Core\Serialization\YamlParserProxy

Hierarchy

Expanded class hierarchy of YamlParserProxy

File

core/tests/Drupal/Tests/Core/Serialization/YamlTest.php, line 41

Namespace

Drupal\Tests\Core\Serialization
View source
class YamlParserProxy implements SerializationInterface {

  /**
   * @var \Drupal\Component\Serialization\SerializationInterface
   */
  protected static $mock;
  public static function setMock($mock) {
    static::$mock = $mock;
  }
  public static function encode($data) {
    return static::$mock
      ->encode($data);
  }
  public static function decode($raw) {
    return static::$mock
      ->decode($raw);
  }
  public static function getFileExtension() {
    return static::$mock
      ->getFileExtension();
  }

}

Members

Namesort descending Modifiers Type Description Overrides
YamlParserProxy::$mock protected static property
YamlParserProxy::decode public static function Decodes data from the serialization format. Overrides SerializationInterface::decode
YamlParserProxy::encode public static function Encodes data into the serialization format. Overrides SerializationInterface::encode
YamlParserProxy::getFileExtension public static function Gets the file extension for this serialization format. Overrides SerializationInterface::getFileExtension
YamlParserProxy::setMock public static function