Audio::TagLib::ID3v1::StringHandler - A abstraction for the string to data


Audio-TagLib documentation  | view source Contained in the Audio-TagLib distribution.

Index


NAME

Top

Audio::TagLib::ID3v1::StringHandler - A abstraction for the string to data encoding in ID3v1 tags.

DESCRIPTION

Top

ID3v1 should in theory always contain ISO-8859-1 (Latin1) data. In practise it does not. Audio::TagLib by default only supports ISO-8859-1 data in ID3v1 tags.

However by subclassing this class and reimplementing parse() and render() and setting your reimplementation as the default with ID3v1::Tag::setStringHandler() you can define how you would like these transformations to be done.

WARNING It is advisable NOT to write non-ISO-8859-1 data to ID3v1 tags. Please consider disabling the writing of ID3v1 tags in the case that the data is ISO-8859-1.

see ID3v1::Tag::setStringHandler()

String parse(ByteVector $data)

Decode a string from $data. The default implementation assumes that $data is an ISO-8859-1 (Latin1) character array.

ByteVector|Audio::TagLib::ByteVector render(String $s)>

Encode a ByteVector with the data from $s. The default implementation assumes that $s is an ISO-8859-1 (Latin1) string.

WARNING It is recommended that you NOT override this method, but instead do not write an ID3v1 tag in the case that the data is not ISO-8859-1.

EXPORT

None by default.

SEE ALSO

Top

Audio::TagLib

AUTHOR

Top

Dongxu Ma, <dongxu@cpan.org>

COPYRIGHT AND LICENSE

Top


Audio-TagLib documentation  | view source Contained in the Audio-TagLib distribution.