MCPcopy Create free account
hub / github.com/acl-dev/acl / convert

Method convert

lib_acl_cpp/src/stdlib/charset_conv.cpp:179–199  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

177}
178
179bool charset_conv::convert(const char* fromCharset, const char* toCharset,
180 const char* in, size_t n, acl::string* out)
181{
182 if (fromCharset == NULL || toCharset == NULL
183 || in == NULL || n == 0 || out == NULL) {
184
185 m_errmsg = "params invalid";
186 return false;
187 }
188
189 if (!update_begin(fromCharset, toCharset)) {
190 reset();
191 return false;
192 }
193 if (!update(in, n, out)) {
194 reset();
195 return false;
196 }
197 update_finish(out);
198 return true;
199}
200
201#define STR acl_vstring_str
202#define LEN ACL_VSTRING_LEN

Callers 11

response_bodyMethod · 0.80
test1Function · 0.80
test2Function · 0.80
test_unicodeFunction · 0.80
load_paramMethod · 0.80
acl_foreachFunction · 0.80
strconvFunction · 0.80
db_sqlite.cppFile · 0.80
transferMethod · 0.80
detactMethod · 0.80
TransformFileMethod · 0.80

Calls 1

updateFunction · 0.50

Tested by 1

test_unicodeFunction · 0.64