H5T.set_strpad

Set storage mechanism for string data type

Syntax

H5T.set_strpad(type_id,storage_type)

Description

H5T.set_strpad(type_id,storage_type) defines the storage mechanism for the string data type identified by type_id. The storage type may be one of the following values.

'H5T_STR_NULLTERM'Null terminated
'H5T_STR_NULLPAD'Padded with zeros
'H5T_STR_SPACEPAD'Padded with spaces

Examples

Create a ten-character string data type with space padding.

type_id = H5T.copy('H5T_C_S1');
H5T.set_size(type_id,10);
H5T.set_strpad(type_id,'H5T_STR_SPACEPAD');