42 #include "qplatformdefs.h" 78 int qvsnprintf(
char *str,
size_t n,
const char *fmt, va_list ap)
89 size_t blen =
qMin(
size_t(ba.
length()),
size_t(n - 1));
103 int qvsnprintf(
char *str,
size_t n,
const char *fmt, va_list ap)
105 return QT_VSNPRINTF(str, n, fmt, ap);
128 int qsnprintf(
char *str,
size_t n,
const char *fmt, ...)
Q_DECL_CONSTEXPR const T & qMin(const T &a, const T &b)
#define QT_END_NAMESPACE
This macro expands to.
The QByteArray class provides an array of bytes.
#define QT_END_INCLUDE_NAMESPACE
This macro is equivalent to QT_BEGIN_NAMESPACE.
The QString class provides a Unicode character string.
QString & vsprintf(const char *format, va_list ap)
Equivalent method to sprintf(), but takes a va_list ap instead a list of variable arguments...
#define QT_BEGIN_NAMESPACE
This macro expands to.
int qvsnprintf(char *str, size_t n, const char *fmt, va_list ap)
A portable vsnprintf() function.
QByteArray toLocal8Bit() const Q_REQUIRED_RESULT
Returns the local 8-bit representation of the string as a QByteArray.
int length() const
Same as size().
const char * constData() const
Returns a pointer to the data stored in the byte array.
int qsnprintf(char *str, size_t n, const char *fmt,...)
A portable snprintf() function, calls qvsnprintf.
#define QT_BEGIN_INCLUDE_NAMESPACE
This macro is equivalent to QT_END_NAMESPACE.