• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdelibs API Reference
  • KDE Home
  • Contact Us
 

Nepomuk-Core

Public Member Functions | List of all members
OptimizedByteArray Class Reference

#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.

Author
Vishesh Handa me@vh.nosp@m.anda.nosp@m..in

Definition at line 44 of file optimizedbytearray.h.

Constructor & Destructor Documentation

OptimizedByteArray::OptimizedByteArray ( )
inline

Definition at line 46 of file optimizedbytearray.h.

OptimizedByteArray::OptimizedByteArray ( const QByteArray &  array,
QSet< QByteArray > &  cache 
)
inline

Definition at line 48 of file optimizedbytearray.h.

Member Function Documentation

bool OptimizedByteArray::operator== ( const OptimizedByteArray &  other) const
inline

Definition at line 83 of file optimizedbytearray.h.

QByteArray OptimizedByteArray::toByteArray ( ) const
inline

Definition at line 67 of file optimizedbytearray.h.


The documentation for this class was generated from the following file:
  • optimizedbytearray.h
This file is part of the KDE documentation.
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.

Nepomuk-Core

Skip menu "Nepomuk-Core"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Modules
  • Related Pages

kdelibs API Reference

Skip menu "kdelibs API Reference"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  • kjsembed
  •   WTF
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Nepomuk-Core
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal