![]() |
Qt 6.x
The Qt SDK
|
#include <qringbuffer_p.h>
Collaboration diagram for QRingBuffer:Public Member Functions | |
| QRingBuffer (int growth=QRINGBUFFER_CHUNKSIZE) | |
| QRingBuffer (QRingBuffer &&) noexcept=default | |
| QRingBuffer & | operator= (QRingBuffer &&) noexcept=default |
| void | setChunkSize (int size) |
| int | chunkSize () const |
| qint64 | nextDataBlockSize () const |
| const char * | readPointer () const |
| Q_CORE_EXPORT const char * | readPointerAtPosition (qint64 pos, qint64 &length) const |
| Q_CORE_EXPORT void | free (qint64 bytes) |
| Q_CORE_EXPORT char * | reserve (qint64 bytes) |
| Q_CORE_EXPORT char * | reserveFront (qint64 bytes) |
| void | truncate (qint64 pos) |
| Q_CORE_EXPORT void | chop (qint64 bytes) |
| bool | isEmpty () const |
| int | getChar () |
| void | putChar (char c) |
| void | ungetChar (char c) |
| qint64 | size () const |
| Q_CORE_EXPORT void | clear () |
| qint64 | indexOf (char c) const |
| Q_CORE_EXPORT qint64 | indexOf (char c, qint64 maxLength, qint64 pos=0) const |
| Q_CORE_EXPORT qint64 | read (char *data, qint64 maxLength) |
| Q_CORE_EXPORT QByteArray | read () |
| Q_CORE_EXPORT qint64 | peek (char *data, qint64 maxLength, qint64 pos=0) const |
| Q_CORE_EXPORT void | append (const char *data, qint64 size) |
| Q_CORE_EXPORT void | append (const QByteArray &qba) |
| Q_CORE_EXPORT void | append (QByteArray &&qba) |
| qint64 | skip (qint64 length) |
| Q_CORE_EXPORT qint64 | readLine (char *data, qint64 maxLength) |
| bool | canReadLine () const |
Definition at line 133 of file qringbuffer_p.h.
|
inlineexplicit |
Definition at line 137 of file qringbuffer_p.h.
|
defaultnoexcept |
Append bytes from data to the end
Definition at line 301 of file qringbuffer.cpp.
References Q_ASSERT, and reserve().
Referenced by QSocks5SocketEnginePrivate::_q_controlSocketReadNotification(), QIODevicePrivate::QRingBufferRef::append(), QIODevicePrivate::QRingBufferRef::append(), and QGstAppSrc::write().
Here is the call graph for this function:
Here is the caller graph for this function:| void QRingBuffer::append | ( | const QByteArray & | qba | ) |
Append a new buffer to the end
Definition at line 320 of file qringbuffer.cpp.
References QByteArray::size().
Here is the call graph for this function:| void QRingBuffer::append | ( | QByteArray && | qba | ) |
Append a new buffer to the end
Definition at line 334 of file qringbuffer.cpp.
|
inline |
Definition at line 219 of file qringbuffer_p.h.
References indexOf().
Referenced by QIODevicePrivate::QRingBufferRef::canReadLine().
Here is the call graph for this function:
Here is the caller graph for this function:Definition at line 165 of file qringbuffer.cpp.
References QRingChunk::capacity(), chunkSize(), clear(), QRingChunk::grow(), QRingChunk::isShared(), MaxByteArraySize, Q_ASSERT, and QRingChunk::reset().
Referenced by QIODevicePrivate::QRingBufferRef::chop().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Definition at line 147 of file qringbuffer_p.h.
Referenced by chop(), QIODevicePrivate::QRingBufferRef::chunkSize(), free(), reserve(), and reserveFront().
Here is the caller graph for this function:| void QRingBuffer::clear | ( | ) |
Definition at line 198 of file qringbuffer.cpp.
Referenced by QSocks5SocketEnginePrivate::_q_controlSocketErrorOccurred(), QSocks5SocketEnginePrivate::_q_emitPendingReadNotification(), chop(), QIODevicePrivate::QRingBufferRef::clear(), free(), and QGStreamerAudioSource::reset().
Here is the caller graph for this function:Definition at line 74 of file qringbuffer.cpp.
References QRingChunk::advance(), QRingChunk::capacity(), chunkSize(), clear(), QRingChunk::isShared(), MaxByteArraySize, Q_ASSERT, and QRingChunk::reset().
Referenced by QIODevicePrivate::QRingBufferRef::free(), and read().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Definition at line 176 of file qringbuffer_p.h.
Referenced by QIODevicePrivate::QRingBufferRef::getChar().
Here is the caller graph for this function:
|
inline |
Definition at line 201 of file qringbuffer_p.h.
References indexOf().
Referenced by QIODevicePrivate::QRingBufferRef::indexOf(), indexOf(), QIODevicePrivate::QRingBufferRef::indexOf(), and readLine().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Definition at line 172 of file qringbuffer_p.h.
Referenced by QIODevicePrivate::QRingBufferRef::isEmpty(), and QSctpSocketPrivate::writeToSocket().
Here is the caller graph for this function:
|
inline |
Definition at line 151 of file qringbuffer_p.h.
References Q_INT64_C.
Referenced by QIODevicePrivate::QRingBufferRef::nextDataBlockSize(), read(), and QSctpSocketPrivate::writeToSocket().
Here is the caller graph for this function:
|
defaultnoexcept |
Peek the bytes from a specified position
Definition at line 273 of file qringbuffer.cpp.
References pos, Q_ASSERT, and qMin().
Referenced by QIODevicePrivate::QRingBufferRef::peek().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Definition at line 184 of file qringbuffer_p.h.
References ptr(), and reserve().
Referenced by QIODevicePrivate::QRingBufferRef::putChar().
Here is the call graph for this function:
Here is the caller graph for this function:| QByteArray QRingBuffer::read | ( | ) |
Read an unspecified amount (will read the first buffer)
Definition at line 259 of file qringbuffer.cpp.
Referenced by readLine().
Here is the caller graph for this function:Definition at line 239 of file qringbuffer.cpp.
References free(), nextDataBlockSize(), qMin(), readPointer(), and size().
Referenced by QIODevicePrivate::QRingBufferRef::read(), QIODevicePrivate::QRingBufferRef::read(), GStreamerInputPrivate::readData(), and QSctpSocketPrivate::writeToSocket().
Here is the call graph for this function:
Here is the caller graph for this function:Definition at line 344 of file qringbuffer.cpp.
References i, indexOf(), Q_ASSERT, and read().
Referenced by QIODevicePrivate::QRingBufferRef::readLine().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Definition at line 155 of file qringbuffer_p.h.
References nullptr.
Referenced by read(), QIODevicePrivate::QRingBufferRef::readPointer(), and QSctpSocketPrivate::writeToSocket().
Here is the caller graph for this function:Access the bytes at a specified position the out-variable length will contain the amount of bytes readable from there, e.g. the amount still the same QByteArray
Definition at line 57 of file qringbuffer.cpp.
Referenced by QIODevicePrivate::QRingBufferRef::readPointerAtPosition().
Here is the caller graph for this function:| char * QRingBuffer::reserve | ( | qint64 | bytes | ) |
Definition at line 107 of file qringbuffer.cpp.
References QRingChunk::available(), chunkSize(), QRingChunk::isShared(), MaxByteArraySize, Q_ASSERT, qMax(), and QRingChunk::size().
Referenced by append(), and QIODevicePrivate::QRingBufferRef::reserve().
Here is the call graph for this function:
Here is the caller graph for this function:| char * QRingBuffer::reserveFront | ( | qint64 | bytes | ) |
Allocate data at buffer head
Definition at line 137 of file qringbuffer.cpp.
References chunkSize(), QRingChunk::grow(), QRingChunk::head(), QRingChunk::isShared(), MaxByteArraySize, Q_ASSERT, and qMax().
Referenced by QIODevicePrivate::QRingBufferRef::reserveFront().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Definition at line 143 of file qringbuffer_p.h.
Referenced by QIODevicePrivate::QRingBufferRef::setChunkSize().
Here is the caller graph for this function:
|
inline |
Definition at line 196 of file qringbuffer_p.h.
Referenced by GStreamerInputPrivate::bytesAvailable(), QGStreamerAudioSource::bytesReady(), QIODevicePrivate::QRingBufferRef::indexOf(), read(), and QIODevicePrivate::QRingBufferRef::size().
Here is the caller graph for this function:Definition at line 210 of file qringbuffer_p.h.
References qMin().
Referenced by QIODevicePrivate::QRingBufferRef::skip().
Here is the call graph for this function:
Here is the caller graph for this function:Definition at line 164 of file qringbuffer_p.h.
Referenced by QIODevicePrivate::QRingBufferRef::truncate().
Here is the caller graph for this function:
|
inline |
Definition at line 189 of file qringbuffer_p.h.
References ptr().
Referenced by QIODevicePrivate::QRingBufferRef::ungetChar().
Here is the call graph for this function:
Here is the caller graph for this function: