MCPcopy Create free account
hub / github.com/amule-project/amule / WriteString

Method WriteString

src/SafeFile.cpp:330–348  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

328
329
330void CFileDataIO::WriteString(const wxString& str, EUtf8Str eEncode, uint8 SizeLen)
331{
332 switch (eEncode) {
333 case utf8strRaw:
334 case utf8strOptBOM: {
335 Unicode2CharBuf s(unicode2UTF8(str));
336 if (s.data()) {
337 WriteStringCore(s, eEncode, SizeLen);
338 break;
339 }
340 }
341 /* fall through */
342 default: {
343 // Non UTF-8 strings are saved as Latin-1
344 wxCharBuffer s1 = str.mb_str(wxConvISO8859_1);
345 WriteStringCore(s1, utf8strNone, SizeLen);
346 }
347 }
348}
349
350
351void CFileDataIO::WriteStringCore(const char *s, EUtf8Str eEncode, uint8 SizeLen)

Callers 11

SendCommentInfoMethod · 0.80
ProcessPacketMethod · 0.80
ProcessExtPacketMethod · 0.80
WriteNewEd2kTagMethod · 0.80
SendChatMessageMethod · 0.80
SendSharedDirectoriesMethod · 0.80
runMethod · 0.80

Calls 1

unicode2UTF8Function · 0.85

Tested by 1

runMethod · 0.64