$include_dir="/home/hyper-archives/boost/include"; include("$include_dir/msg-header.inc") ?>
From: Atry (pop.atry_at_[hidden])
Date: 2007-08-11 15:23:25
I wrote a text_encoding library provide generic container and iterator
with charset infomation. I have used it for some weeks.Use this library,
you may write code like:
// convert UCS-2 to UTF-8
utf8_string us = L"some wide character: \xABCD\x1234";
cout << us << endl;
string s;
// move bytes to another std::string.
us.swap(s);
Or, use iterators:
wstring ws = L"some wide character: \xABCD\x1234";
copy (
make_encoded_range<charset::utf8>(ws).begin(),
make_encoded_range<charset::utf8>(ws).end(),
ostreambuf_iterator<char>(std::cout)
);
The version I upload to vault already have a little of tests, examples,
and documents.
directory url:
http://boost-consulting.com/vault/index.php?direction=0&order=&directory=Strings%20-%20Text%20Processing&
file name: text_encoding.zip