createLanguageContext example

'parent' => [
                        Defaults::LANGUAGE_SYSTEM => ['customFields' => ['foo' => 'parent'], 'name' => 'A'],
                    ],
                    'child' => [
                        Defaults::LANGUAGE_SYSTEM => ['customFields' => ['foo' => 'child'], 'name' => 'A'],
                    ],
                ],
                [
                    'parent' => ['foo' => 'parent'],
                    'child' => ['foo' => 'child'],
                ],
                self::createLanguageContext([Defaults::LANGUAGE_SYSTEM], true),
            ],
            'Test merged with parent' => [
                [
                    'parent' => [
                        Defaults::LANGUAGE_SYSTEM => ['customFields' => ['foo' => 'parent', 'bar' => 'parent'], 'name' => 'A'],
                    ],
                    'child' => [
                        Defaults::LANGUAGE_SYSTEM => ['customFields' => ['foo' => 'child'], 'name' => 'A'],
                    ],
                ],
                [
                    
if ($offset->getLanguageId() === null) {
            return null;
        }

        $language = $this->getLanguageForId($offset->getLanguageId());

        if (!$language) {
            return null;
        }

        $context = $this->createLanguageContext($language);

        // current language has next message?         $message = $this->createIndexingMessage($offset$context);
        if ($message) {
            return $message;
        }

        // all definitions in all languages indexed         if (!$offset->hasNextLanguage()) {
            return null;
        }

        
Home | Imprint | This part of the site doesn't use cookies.