for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* Map general ObjectStorage.
*/
declare(strict_types = 1);
namespace HDNET\Autoloader\Mapper;
use HDNET\Autoloader\MapperInterface;
class ObjectStorageMapper implements MapperInterface
{
* Check if the current mapper can handle the given type.
*
* @param string $type
* @return bool
public function canHandleType($type)
return false !== mb_stristr(trim($type, '\\'), 'typo3\\cms\\extbase\\persistence\\objectstorage');
}
* Get the TCA configuration for the current type.
* @param string $fieldName
* @param bool $overWriteLabel
* @return array
public function getTcaConfiguration($fieldName, $overWriteLabel = false)
$baseConfig = [
'type' => 'user',
'userFunc' => 'HDNET\\Autoloader\\UserFunctions\\Tca->objectStorageInfoField',
];
return [
'exclude' => 1,
'label' => $overWriteLabel ? $overWriteLabel : $fieldName,
'config' => $baseConfig,
* Get the database definition for the current mapper.
* @return string
public function getDatabaseDefinition()
return 'varchar(255) DEFAULT \'\' NOT NULL';