Nepomuk-Core
#include <optimizedbytearray.h>
Public Member Functions | |
OptimizedByteArray () | |
OptimizedByteArray (const QByteArray &array, QSet< QByteArray > &cache) | |
bool | operator== (const OptimizedByteArray &other) const |
QByteArray | toByteArray () const |
Detailed Description
This class holds a QByteArray which corresponds to a file url in a more memory efficient manner.
It does so by spliting the url along the directory separator '/', and saving each path separately in a QVector. This is more memory efficient than storing it together cause it uses a QSet<QByteArray> cache to lookup each part of the vector. This way, multiple OptimizedByteArrays share common parts of the url. This happens because Qt's containers are reference counted.
Definition at line 44 of file optimizedbytearray.h.
Constructor & Destructor Documentation
|
inline |
Definition at line 46 of file optimizedbytearray.h.
|
inline |
Definition at line 48 of file optimizedbytearray.h.
Member Function Documentation
|
inline |
Definition at line 83 of file optimizedbytearray.h.
|
inline |
Definition at line 67 of file optimizedbytearray.h.
The documentation for this class was generated from the following file:
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:48:09 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.