protected function getTypeMap($type)
{
/**
* Some of these types are described here:
* http://trac.greenstone.org/browser/main/trunk/greenstone2/perllib/cpan/Image/ExifTool/README
* http://cpansearch.perl.org/src/EXIFTOOL/Image-ExifTool-9.13/lib/Image/ExifTool/PICT.pm
*/
switch ($type) {
# Formats defined in the wiki
case 'int8s':
case 'int8u':
case 'int16s':
case 'int16u':
case 'int16uRev':
case 'int32s':
case 'int32u':
case 'int64s':
case 'int64u':
case 'rational32s':
case 'rational32u':
case 'rational64s':
case 'rational64u':
case 'fixed16s':
case 'fixed32s':
case 'fixed32u':
case 'var_int16u':
# Apple data structures in PICT images
# Apple data structures in PICT images
case 'Int8uText':
case 'Int8u2Text':
case 'Int16Data':
case 'Int32uData':
# Source unknown ...
# Source unknown ...
case 'var_int8u':
case 'rational':
case 'integer':
case 'real':
case 'digits':
case 'signed':
case 'unsigned':
return 'int';
break;
# Formats defined in the wiki
# Formats defined in the wiki
case 'float':
case 'double':
case 'extended':
return 'float';
break;
# Formats defined in the wiki
# Formats defined in the wiki
case 'undef':
case 'binary':
# Source unknown ...
# Source unknown ...
case 'var_undef':
case '?':
case 'null':
case 'unknown':
case 'Unknown':
return 'binary';
break;
# Formats defined in the wiki
# Formats defined in the wiki
case 'string':
case 'pstring':
case 'var_string':
case 'var_pstr32':
# Apple data structures in PICT images
# Apple data structures in PICT images
case 'Arc':
case 'BitsRect#':
# version-depended
# version-depended
case 'BitsRgn#':
# version-depended
# version-depended
case 'CompressedQuickTime':
case 'DirectBitsRect':
case 'DirectBitsRgn':
case 'FontName':
case 'PixPat':
case 'Point':
case 'PointText':
case 'Polygon':
case 'Rect':
case 'RGBColor':
case 'Rgn':
case 'ShortLine':
# Source unknown ...
# Source unknown ...
case 'lang-alt':
case 'resize':
case 'utf8':
return 'string';
break;
# Source unknown ...
# Source unknown ...
case 'date':
return 'date';
break;
# Source unknown ...
# Source unknown ...
case 'boolean':
return 'boolean';
break;
default:
$this->output->writeln(sprintf("No type found for %s", $type));
break;
}
return;
}