Convert parameters using methods of this utility class

@param source
Array of source object
@param target
Array of target classes
@return Array of converted objects
@throws ConversionException
If object can't be converted
345311
public static Object[] convertParams(Object[] source, Class<?>[] target) throws ConversionException {
        Object[] converted = new Object[target.length];
        for (int i = 0; i < target.length; i++) {
            converted[i] = convert(source[i], target[i]);
        }
        return converted;
    }
22947
public function convertFrom($source, $targetType, array $convertedChildProperties = array(), PropertyMappingConfigurationInterface $configuration = NULL) {
		$object = $this->buildObject($convertedChildProperties, $targetType);
		foreach ($convertedChildProperties as $propertyName => $propertyValue) {
			ObjectAccess::setProperty($object, $propertyName, $propertyValue);
		}

		return $object;
	}
512563
protected function getTypeConverter($source, $targetType, $configuration)
    {
        $compositeType = $this->parseCompositeType($targetType);

        if (in_array($compositeType, ['\\ArrayObject', 'array'])) {
            $typeConverter = $this->objectManager->get(ArrayConverter::class);
        } else {
            $typeConverter = $this->findTypeConverter($source, $targetType, $configuration);

            if ($typeConverter instanceof ExtbaseArrayConverter) {
                $typeConverter = $this->objectManager->get(ArrayConverter::class);
            } elseif ($typeConverter instanceof ObjectConverter) {
                $typeConverter = $this->getObjectConverter();
            }
        }

        if (!is_object($typeConverter) || !$typeConverter instanceof TypeConverterInterface) {
            throw new TypeConverterException('Type converter for "' . $source . '" -> "' . $targetType . '" not found.');
        }

        return $typeConverter;
    }
121790
public static ConversionType getConversionType(final Class<?> destination, final Class<?> source){
		
		if(destination == String.class)   return toStringConversion(source);
		if(destination == Byte.class)     return toByteConversion(source);
		if(destination == byte.class)     return tobyteConversion(source);
		if(destination == Short.class)    return toShortConversion(source);
		if(destination == short.class)    return toshortConversion(source);
		if(destination == Integer.class)  return toIntegerConversion(source);
		if(destination == int.class)      return tointConversion(source);
		if(destination == Long.class)     return toLongConversion(source);
		if(destination == long.class)     return tolongConversion(source);
		if(destination == Float.class)    return toFloatConversion(source);
		if(destination == float.class)    return tofloatConversion(source);
		if(destination == Double.class)   return toDoubleConversion(source);
		if(destination == double.class)   return todoubleConversion(source);
		if(destination == Character.class)return toCharacterConversion(source);
		if(destination == char.class)     return tocharConversion(source);
		if(destination == Boolean.class)  return toBooleanConversion(source);
		if(destination == boolean.class)  return tobooleanConversion(source);
		return UNDEFINED;
	}
779923
private <T> Converter<T> lookupConverter(Type targetType)
    {
        // Try with complete type
        Converter<T> converter = getConverter(targetType);

        // Try with simple class
        if (converter == null && targetType instanceof ParameterizedType) {
            Class<?> targetClass = ReflectionUtils.getTypeClass(targetType);
            converter = getConverter(targetClass);
        }

        if (converter == null) {
            if (targetType instanceof Class && Enum.class.isAssignableFrom((Class<?>) targetType)) {
                // It's an Enum
                converter = (Converter<T>) this.enumConverter;
            } else {
                // Fallback on default converter

                this.logger.debug("Using the default Converter for type [{}]", targetType);

                converter = this.defaultConverter;
            }
        }

        return converter;
    }
646675
def to(target, options = {})
      conversion = conversions[source || detect(object, false), detect(target)]
      conversion.call(object, options)
    end
361699
@Override
  public <S,T> Convert<S,T> converter(Class<S> source, Class<T> target)
  {
    return _injectBuilder.get().converter().converter(source, target);
  }
1257959
public void addConverter(Converter<?, ?> converter) {
		GenericConverter.ConvertiblePair typeInfo = getRequiredTypeInfo(converter, Converter.class);
		Assert.notNull(typeInfo, "Unable to the determine sourceType <S> and targetType " +
				"<T> which your Converter<S, T> converts between; declare these generic types.");
		addConverter(new ConverterAdapter(converter, typeInfo));
	}
476558
@Override
  public <S, T> Convert<S, T> converter(Class<S> source, Class<T> target)
  {
    ConvertFrom<S> convertType = getOrCreate(source);
    
    return convertType.converter(target);
  }
685315
@Override
    protected Object[] convertParameters(Object[] params) {
        List<Object> converted = getBinding().getKeyBinding().getKeyParameters(Arrays.asList(params));
        return converted.toArray(new Object[converted.size()]);
    }
1153439
public static <S, T> Convert<S, T> to(Class<T> targetType, Position.Readable<S> sourcePosition) {
        return new Convert<>(sourcePosition, targetType);
    }
841344
public function convertFrom($source, $targetType, array $convertedChildProperties = [], PropertyMappingConfigurationInterface $configuration = null)
    {
        if (is_bool($source)) {
            return $source;
        }

        if (is_int($source) || is_float(($source))) {
            return (boolean)$source;
        }

        return (!empty($source) && !in_array(strtolower($source), ['off', 'n', 'no', 'false']));
    }
424767
public <S, T> ToMarshaller<S, T> findMarshaller(Class<S> source, Class<T> target) {
		return findMarshaller(new ConverterKey<S,T>(source, target, DefaultBinding.class));
	}
1046273
private static <T, U> U convertBean(T source, Class<U> targetClass, Handler handler) {
        try {
            if (Objects.isNull(source)) {
                return null;
            }
            return targetClass.cast(handler.getMethod().invoke(handler.getHandler(), source));
        } catch (IllegalAccessException | InvocationTargetException e) {
            throw ConvertException.of("Call method \"" + handler.getMethod() + "\" failed", e);
        }
    }
1110564
private @NotNull Optional<List<TypeConversion>> resolveConversions(@NotNull NamedTypeList sourceTypes, @NotNull List<Type> targetTypes) {
        if (targetTypes.size() != sourceTypes.size())
            return Optional.empty();

        ArrayList<TypeConversion> conversions = new ArrayList<>(targetTypes.size());

        for (int i = 0, len = targetTypes.size(); i < len; i++) {
            TypeConversion conversion = findConversionFromDbValue(sourceTypes.getType(i), targetTypes.get(i)).orElse(null);
            if (conversion != null)
                conversions.add(conversion);
            else
                return Optional.empty();
        }

        return Optional.of(conversions);
    }
314139
public static <E, T> List<E> convert(List<T> source, Class<E> targetClass) {
        return BeansConvertStrategy.convertBeans(source, targetClass, false);
    }
180815
public static <T, U, X extends RuntimeException> U convertIfNullThrow(T source, Class<U> targetClass,
            Supplier<X> exceptionSupplier) {
        return BeanConvertStrategy.convertBean(source, targetClass, exceptionSupplier);
    }