DIUnicode offers Unicode text writer and reader classes, with automated conversion between the 144 character sets and encoders that work with Delphi (Embarcadero, CodeGear, Borland).
DIUnicode's Pascal implementation comes with more than 70 encodings, including UTF-7, UTF-8, UTF-16, ISO-8859, and a range of Windows and Macintosh codes, KOI8 characters, Chinese GB18030, and many more. Adding a new code for characters is as easy as writing a straightforward conversion procedure. It can support 144 character sets and encodings linked to DIConverters.
DIUnicode is the right choice when your application must process text using multiple-character encoders with high performance and minimal development time.
Unicode Reader, the Unicode Reader, and Unicode Writer use buffers, strings, and streams. You can, for instance, directly read data from databases or write to databases BLOB streams to avoid all the temporary data storage.
A reliable buffering system will guarantee high performance even when dealing with large files.
DIUnicode does writing and reading Unicode as quickly as it can ASCII text, irrespective of the encoded or character set you're processing. Below are code snippets demonstrating some of the methods commonly employed in TDIUnicodeReader, the reader class part of DIUnicode. Be aware that you can similarly run the parsing function on any encodings available.
In contrast to other text readers, the lookahead functions of TDIUnicodeReader do not limit you to a set number of characters but are limited by the memory available. The code below can read up to five Unicode characters from the buffer inside. TDIUnicodeReader can look ahead further, but it is not a good idea, and the number of characters reads should be kept to a minimum.