protected function convertChildProperties(array $source, $targetType, TypeConverterInterface $typeConverter, PropertyMappingConfigurationInterface $configuration, array &$currentPropertyPath)
    {
        $convertedChildProperties = [];
        $properties = $source;

        // If the target is a class, we get its properties, else we assume the source should be converted.
        if (Core::get()->classExists($targetType)) {
            $properties = $this->getProperties($targetType);
        }

        foreach ($source as $propertyName => $propertyValue) {
            if (array_key_exists($propertyName, $properties)) {
                $currentPropertyPath[] = $propertyName;
                $targetPropertyType = $typeConverter->getTypeOfChildProperty($targetType, $propertyName, $configuration);
                $targetPropertyTypeBis = $this->checkMixedTypeAnnotationForProperty($targetType, $propertyName, $targetPropertyType);
                $targetPropertyType = $targetPropertyTypeBis ?: $targetPropertyType;

                $targetPropertyValue = (null !== $targetPropertyType)
                    ? $this->doMapping($propertyValue, $targetPropertyType, $configuration, $currentPropertyPath)
                    : $propertyValue;

                array_pop($currentPropertyPath);

                if (false === $targetPropertyValue instanceof Error) {
                    $convertedChildProperties[$propertyName] = $targetPropertyValue;
                }
            }
        }

        return $convertedChildProperties;
    }