Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. AbstractNormalizer.php

function AbstractNormalizer::getGroups

3 calls to AbstractNormalizer::getGroups()
AbstractNormalizer::getAllowedAttributes in vendor/symfony/serializer/Normalizer/AbstractNormalizer.php
Gets attributes to normalize using groups.
AbstractNormalizer::getAttributeDenormalizationContext in vendor/symfony/serializer/Normalizer/AbstractNormalizer.php
Computes the denormalization context merged with current one. Metadata always wins over global context, as more specific.
AbstractNormalizer::getAttributeNormalizationContext in vendor/symfony/serializer/Normalizer/AbstractNormalizer.php
Computes the normalization context merged with current one. Metadata always wins over global context, as more specific.

File

vendor/symfony/serializer/Normalizer/AbstractNormalizer.php, line 253

Class

AbstractNormalizer
Normalizer implementation.

Namespace

Symfony\Component\Serializer\Normalizer

Code

protected function getGroups(array $context) : array {
    $groups = $context[self::GROUPS] ?? $this->defaultContext[self::GROUPS] ?? [];
    return \is_scalar($groups) ? (array) $groups : $groups;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal