TYPO3 CMS  TYPO3_6-2
TYPO3\CMS\Extbase\Property\TypeConverter\FloatConverter Class Reference
Inheritance diagram for TYPO3\CMS\Extbase\Property\TypeConverter\FloatConverter:
TYPO3\CMS\Extbase\Property\TypeConverter\AbstractTypeConverter TYPO3\CMS\Extbase\Property\TypeConverterInterface TYPO3\CMS\Core\SingletonInterface Tx_Extbase_Property_TypeConverter_FloatConverter

Public Member Functions

 convertFrom ($source, $targetType, array $convertedChildProperties=array(), \TYPO3\CMS\Extbase\Property\PropertyMappingConfigurationInterface $configuration=NULL)
 
- Public Member Functions inherited from TYPO3\CMS\Extbase\Property\TypeConverter\AbstractTypeConverter
 getSupportedSourceTypes ()
 
 getSupportedTargetType ()
 
 getTargetTypeForSource ($source, $originalTargetType, \TYPO3\CMS\Extbase\Property\PropertyMappingConfigurationInterface $configuration=NULL)
 
 getPriority ()
 
 canConvertFrom ($source, $targetType)
 
 getSourceChildPropertiesToBeConverted ($source)
 
 getTypeOfChildProperty ($targetType, $propertyName, \TYPO3\CMS\Extbase\Property\PropertyMappingConfigurationInterface $configuration)
 
- Public Member Functions inherited from TYPO3\CMS\Extbase\Property\TypeConverterInterface
 getTargetTypeForSource ($source, $originalTargetType, PropertyMappingConfigurationInterface $configuration=NULL)
 

Protected Attributes

 $sourceTypes = array('float', 'integer', 'string')
 
 $targetType = 'float'
 
 $priority = 1
 
- Protected Attributes inherited from TYPO3\CMS\Extbase\Property\TypeConverter\AbstractTypeConverter
 $sourceTypes = array()
 
 $targetType = ''
 
 $priority
 
 $objectManager
 

Detailed Description

Converter which transforms a simple type to a float.

This is basically done by simply casting it.

Definition at line 30 of file FloatConverter.php.

Member Function Documentation

◆ convertFrom()

TYPO3\CMS\Extbase\Property\TypeConverter\FloatConverter::convertFrom (   $source,
  $targetType,
array  $convertedChildProperties = array(),
\TYPO3\CMS\Extbase\Property\PropertyMappingConfigurationInterface  $configuration = NULL 
)

Actually convert from $source to $targetType, by doing a typecast.

Parameters
mixed$source
string$targetType
array$convertedChildProperties
\TYPO3\CMS\Extbase\Property\PropertyMappingConfigurationInterface$configuration
Returns
float|

Implements TYPO3\CMS\Extbase\Property\TypeConverterInterface.

Definition at line 57 of file FloatConverter.php.

Member Data Documentation

◆ $priority

TYPO3\CMS\Extbase\Property\TypeConverter\FloatConverter::$priority = 1
protected

Definition at line 45 of file FloatConverter.php.

◆ $sourceTypes

TYPO3\CMS\Extbase\Property\TypeConverter\FloatConverter::$sourceTypes = array('float', 'integer', 'string')
protected

Definition at line 35 of file FloatConverter.php.

◆ $targetType

TYPO3\CMS\Extbase\Property\TypeConverter\FloatConverter::$targetType = 'float'
protected

Definition at line 40 of file FloatConverter.php.