setVisibility(self::VISIBILITY_PRIVATE); $this->setStatic(true); $this->setDocBlock( '@var string[][] declaring class name of defined protected properties, indexed by property name' ); $this->setDefaultValue($this->getMap($properties)); } /** @return string[] */ private function getMap(Properties $properties): array { $map = []; foreach ($properties->getProtectedProperties() as $property) { if (\PHP_VERSION_ID >= 80100 && $property->isReadOnly()) { continue; } $map[$property->getName()] = $property->getDeclaringClass()->getName(); } return $map; } }