| TagLib 1.13 |  |

Public Member Functions | List of all members
TagLib::RIFF::Info::StringHandler Class Reference

A abstraction for the string to data encoding in Info tags. More...

`#include <infotag.h>`

## Public Member Functions
| StringHandler ()
| ~StringHandler ()
virtual String | parse (const ByteVector &data) const
virtual ByteVector | render (const String &s) const

## Detailed Description

A abstraction for the string to data encoding in Info tags.

RIFF INFO tag has no clear definitions about character encodings. In practice, local encoding of each system is largely used and UTF-8 is popular too.

Here is an option to read and write tags in your preferred encoding by subclassing this class, reimplementing parse() and render() and setting your reimplementation as the default with Info::Tag::setStringHandler().

See also
  ID3v1::Tag::setStringHandler()

## Constructor & Destructor Documentation

## ◆ StringHandler()

TagLib::RIFF::Info::StringHandler::StringHandler | ( |  | ) |

## ◆ ~StringHandler()

TagLib::RIFF::Info::StringHandler::~StringHandler | ( |  | ) |

## Member Function Documentation

## ◆ parse()

virtual String TagLib::RIFF::Info::StringHandler::parse | ( | const ByteVector & | data | ) | const
| virtual

Decode a string from data. The default implementation assumes that data is an UTF-8 character array.

## ◆ render()

virtual ByteVector TagLib::RIFF::Info::StringHandler::render | ( | const String & | s | ) | const
| virtual

Encode a ByteVector with the data from s. The default implementation assumes that s is an UTF-8 string.

The documentation for this class was generated from the following file:

- infotag.h