mini\Converter\ConverterRegistryInterface::get() Method

public abstract

Signature

public abstract function get(mixed $input, string $targetType, ?string $sourceType = NULL): ?mini\Converter\ConverterInterface

Parameters

Name Type Default Description
$input mixed required Documentation missing
$targetType string required Documentation missing
$sourceType ?string NULL Documentation missing

Returns

?mini\Converter\ConverterInterface

Documentation

Get the converter for input to target type

Returns the most specific converter based on type hierarchy:

  1. Direct single-type converter (most specific)
  2. Union type converter (less specific)
  3. Parent class converters
  4. Interface converters

Source

src/Converter/ConverterRegistryInterface.php:130