# QByteArray Class Reference

### [com.trolltech.qt.core package]

### Constructor

- void QByteArray()
- void QByteArray(QByteArray arg__1)
- void QByteArray(char arg__1)
- void QByteArray(int size, char c)

### Constructor Properties

- prototype: The QByteArray prototype object
- QByteArray fromBase64(QByteArray base64)
- QByteArray fromHex(QByteArray hexEncoded)
- QByteArray fromInt(int arg__1, int base)
- QByteArray fromLongLong(qlonglong arg__1, int base)
- QByteArray fromPercentEncoding(QByteArray pctEncoded, char percent)
- QByteArray number(double arg__1, char f, int prec)

### Prototype Object Properties

- QByteArray append(QByteArray a)
- QByteArray appendByte(char c)
- char at(int i)
- int capacity()
- void chop(int n)
- void clear()
- int count(char c)
- bool endsWith(char c)
- QByteArray fill(char c, int size)
- int indexOf(QByteArray a, int from)
- int indexOfByte(char c, int from)
- QByteArray insert(int i, QByteArray a)
- QByteArray insertByte(int i, char c)
- bool isEmpty()
- bool isNull()
- bool isSharedWith(QByteArray other)
- int lastIndexOf(QByteArray a, int from)
- int lastIndexOfByte(char c, int from)
- QByteArray left(int len)
- QByteArray leftJustified(int width, char fill, bool truncate)
- int length()
- QByteArray mid(int index, int len)
- QByteArray operator_assign(QByteArray arg__1)
- bool operator_equal(QByteArray a2)
- bool operator_less(QByteArray a2)
- QByteArray prepend(QByteArray a)
- QByteArray prependByte(char c)
- void readFrom(QDataStream arg__1)
- QByteArray remove(int index, int len)
- QByteArray repeated(int times)
- QByteArray replace(char before, char after)
- void reserve(int size)
- void resize(int size)
- QByteArray right(int len)
- QByteArray rightJustified(int width, char fill, bool truncate)
- QByteArray setDouble(double arg__1, char f, int prec)
- QByteArray setFloat(float arg__1, char f, int prec)
- QByteArray setInt(int arg__1, int base)
- QByteArray setLongLong(qlonglong arg__1, int base)
- QByteArray setRawData(char a, uint n)
- QByteArray setShort(short arg__1, int base)
- QByteArray simplified()
- int size()
- List split(char sep)
- void squeeze()
- bool startsWith(char c)
- void swap(QByteArray other)
- QByteArray toBase64()
- double toDouble()
- float toFloat()
- QByteArray toHex()
- int toInt(int base)
- QByteArray toLower()
- QByteArray toPercentEncoding(QByteArray exclude, QByteArray include, char percent)
- ushort toUShort(int base)
- QByteArray toUpper()
- QByteArray trimmed()
- void truncate(int pos)
- void writeTo(QDataStream arg__1)

### Instance Properties

QByteArray objects have no special properties beyond those inherited from the QByteArray prototype object.