class TestNormalizerBase

Same name and namespace in other branches
  1. 9 core/modules/serialization/tests/src/Unit/Normalizer/NormalizerBaseTest.php \Drupal\Tests\serialization\Unit\Normalizer\TestNormalizerBase
  2. 10 core/modules/serialization/tests/src/Unit/Normalizer/NormalizerBaseTest.php \Drupal\Tests\serialization\Unit\Normalizer\TestNormalizerBase
  3. 11.x core/modules/serialization/tests/src/Unit/Normalizer/NormalizerBaseTest.php \Drupal\Tests\serialization\Unit\Normalizer\TestNormalizerBase

Test class for NormalizerBase.

Hierarchy

Expanded class hierarchy of TestNormalizerBase

File

core/modules/serialization/tests/src/Unit/Normalizer/NormalizerBaseTest.php, line 69

Namespace

Drupal\Tests\serialization\Unit\Normalizer
View source
abstract class TestNormalizerBase extends NormalizerBase {
    
    /**
     * Sets the protected supportedInterfaceOrClass property.
     *
     * @param string $supported_interface_or_class
     *   The class name to set.
     */
    public function setSupportedInterfaceOrClass($supported_interface_or_class) {
        $this->supportedInterfaceOrClass = $supported_interface_or_class;
    }

}

Members

Title Sort descending Modifiers Object type Summary Overrides
CacheableNormalizerInterface::SERIALIZATION_CONTEXT_CACHEABILITY constant Name of key for bubbling cacheability metadata via serialization context.
NormalizerBase::$format protected property List of formats which supports (de-)normalization. 3
NormalizerBase::$supportedInterfaceOrClass protected property The interface or class that this Normalizer supports. 22
NormalizerBase::addCacheableDependency protected function Adds cacheability if applicable.
NormalizerBase::checkFormat protected function Checks if the provided format is supported by this normalizer. 2
NormalizerBase::supportsDenormalization public function Implements \Symfony\Component\Serializer\Normalizer\DenormalizerInterface::supportsDenormalization() 1
NormalizerBase::supportsNormalization public function 1
TestNormalizerBase::setSupportedInterfaceOrClass public function Sets the protected supportedInterfaceOrClass property.

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.