src/Serializer.php
private function doDeserializeBaseProperty($type, $value)
    {
        $isAnnotationClass = is_string($type) && is_subclass_of(trim($type, '[]'), AbstractAnnotation::class);

        if ($isAnnotationClass) {
            $isArray = strpos($type, '[') === 0 && substr($type, -1) === ']';

            if ($isArray) {
                $annotationArr = [];
                $class = trim($type, '[]');

                foreach ($value as $v) {
                    $annotationArr[] = $this->doDeserialize($v, $class);
                }
                return $annotationArr;
            }

            return $this->doDeserialize($value, $type);
        }

        return $value;
    }
private function doDeserializeBaseProperty($type, $value)
    {
        $isAnnotationClass = is_string($type) && is_subclass_of(trim($type, '[]'), AbstractAnnotation::class);

        if ($isAnnotationClass) {
            $isArray = strpos($type, '[') === 0 && substr($type, -1) === ']';

            if ($isArray) {
                $annotationArr = [];
                $class = trim($type, '[]');

                foreach ($value as $v) {
                    $annotationArr[] = $this->doDeserialize($v, $class);
                }
                return $annotationArr;
            }

            return $this->doDeserialize($value, $type);
        }

        return $value;
    }
private function doDeserializeBaseProperty ( $ type , $ value ) { $ isAnnotationClass = is_string ( $ type ) && is_subclass_of ( trim ( $ type , '[]' ) , AbstractAnnotation :: class ) ; if ( $ isAnnotationClass ) { $ isArray = strpos ( $ type , '[' ) === 0 && substr ( $ type , - 1 ) === ']' ; if ( $ isArray ) { $ annotationArr = [ ] ; $ class = trim ( $ type , '[]' ) ; foreach ( $ value as $ v ) { $ annotationArr [ ] = $ this -> doDeserialize ( $ v , $ class ) ; } return $ annotationArr ; } return $ this -> doDeserialize ( $ value , $ type ) ; } return $ value ; }
Deserialize base annotation property

@param string $type The property type
@param mixed $value The value to deserialization

@return array|\OpenApi\Annotations\AbstractAnnotation
Deserialize base annotation property