Closed 1647606255 closed 3 years ago
Example: QString QString().sprintf(...) look like as printf() . number:QString::number(number, ‘f’, 3); string:QString s=QString("username=%s,pw=%s").arg("Anson").agr("123456")
Example:CString CString str; double num=1.46; str.Format(_T("%lf"),num); str.Format(_T("%s"),"test");
Example:java String str=null; str=String.format("Hi,%s", "王力"); System.out.println(str); str=String.format("Hi,%s:%s.%s", "王南","王力","王张");
I'm not to add a format
, instead, I provide a cat
.
fastring s = str::cat("Hi,", "kakalot", ':', 123);
s.cat(false, " nice ", 3.14);
fastring add a fomatting function.