void MakeLowerCaseInplace(string & s) { UniString uniStr; utf8::unchecked::utf8to32(s.begin(), s.end(), back_inserter(uniStr)); MakeLowerCaseInplace(uniStr); s.clear(); utf8::unchecked::utf32to8(uniStr.begin(), uniStr.end(), back_inserter(s)); }
/// @warning unistring S must be not temporary! TokenizeIterator(UniString const & s, DelimFuncT const & delimFunc) : m_beg(s.begin()), m_end(s.begin()), m_finish(s.end()), m_delimFunc(delimFunc) { move(); }
// *NOTE* |s| must be not temporary! TokenizeIterator(UniString const & s, TDelimFn const & delimFn) : m_start(s.begin()), m_end(s.begin()), m_finish(s.end()), m_delimFn(delimFn), m_finished(false) { while (m_end != m_finish && !m_delimFn(*m_end)) ++m_end; }
// *NOTE* |s| must be not temporary! TokenizeIterator(UniString const & s, TDelimFn const & delimFn) : m_start(s.begin()), m_end(s.begin()), m_finish(s.end()), m_delimFn(delimFn) { Move(); }
string ToUtf8(UniString const & s) { string result; utf8::unchecked::utf32to8(s.begin(), s.end(), back_inserter(result)); return result; }