Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
IMap< Key, Value > Class Template Reference

Indexed map template class.

#include <QtxMap.h>

Public Types

typedef IMapIterator< Key, Value > Iterator
 
typedef IMapConstIterator< Key,
Value > 
ConstIterator
 

Public Member Functions

 IMap ()
 
 IMap (const IMap &m)
 
IMapoperator= (const IMap &m)
 
int count () const
 
int size () const
 
bool empty () const
 
bool isEmpty () const
 
void clear ()
 
QList< Key > keys () const
 
QList< Value > values () const
 
bool contains (const Key &key) const
 
Iterator begin ()
 
Iterator end ()
 
ConstIterator begin () const
 
ConstIterator end () const
 
Iterator insert (const Key &key, const Value &value, bool overwrite=true)
 
Iterator replace (const Key &key, const Value &value)
 
int index (const Key &key) const
 
Iterator at (const int index)
 
ConstIterator at (const int index) const
 
Key & key (const int index)
 
Value value (const int index)
 
Value operator[] (const Key &key)
 
const Value operator[] (const Key &key) const
 
void erase (Iterator it)
 
void erase (const Key &key)
 
void erase (const int index)
 
void remove (Iterator it)
 
void remove (const Key &key)
 
void remove (const int index)
 

Private Attributes

QList< Key > myKeys
 
QMap< Key, Value > myData
 
Key dummyKey
 
Value dummyValue
 

Friends

class IMapIterator< Key, Value >
 
class IMapConstIterator< Key, Value >
 

Member Typedef Documentation

template<class Key, class Value>
typedef IMapConstIterator<Key,Value> IMap< Key, Value >::ConstIterator
template<class Key, class Value>
typedef IMapIterator<Key,Value> IMap< Key, Value >::Iterator

Constructor & Destructor Documentation

template<class Key, class Value>
IMap< Key, Value >::IMap ( )
inline
template<class Key, class Value>
IMap< Key, Value >::IMap ( const IMap< Key, Value > &  m)
inline

Member Function Documentation

template<class Key, class Value>
Iterator IMap< Key, Value >::at ( const int  index)
inline
template<class Key, class Value>
ConstIterator IMap< Key, Value >::at ( const int  index) const
inline
template<class Key, class Value>
Iterator IMap< Key, Value >::begin ( )
inline
template<class Key, class Value>
ConstIterator IMap< Key, Value >::begin ( ) const
inline
template<class Key, class Value>
void IMap< Key, Value >::clear ( )
inline
template<class Key, class Value>
bool IMap< Key, Value >::contains ( const Key &  key) const
inline
template<class Key, class Value>
int IMap< Key, Value >::count ( ) const
inline
template<class Key, class Value>
bool IMap< Key, Value >::empty ( ) const
inline
template<class Key, class Value>
Iterator IMap< Key, Value >::end ( )
inline
template<class Key, class Value>
ConstIterator IMap< Key, Value >::end ( ) const
inline
template<class Key, class Value>
void IMap< Key, Value >::erase ( Iterator  it)
inline
template<class Key, class Value>
void IMap< Key, Value >::erase ( const Key &  key)
inline
template<class Key, class Value>
void IMap< Key, Value >::erase ( const int  index)
inline
template<class Key, class Value>
int IMap< Key, Value >::index ( const Key &  key) const
inline
template<class Key, class Value>
Iterator IMap< Key, Value >::insert ( const Key &  key,
const Value &  value,
bool  overwrite = true 
)
inline
template<class Key, class Value>
bool IMap< Key, Value >::isEmpty ( ) const
inline
template<class Key, class Value>
Key& IMap< Key, Value >::key ( const int  index)
inline
template<class Key, class Value>
QList<Key> IMap< Key, Value >::keys ( ) const
inline
template<class Key, class Value>
IMap& IMap< Key, Value >::operator= ( const IMap< Key, Value > &  m)
inline
template<class Key, class Value>
Value IMap< Key, Value >::operator[] ( const Key &  key)
inline
template<class Key, class Value>
const Value IMap< Key, Value >::operator[] ( const Key &  key) const
inline
template<class Key, class Value>
void IMap< Key, Value >::remove ( Iterator  it)
inline
template<class Key, class Value>
void IMap< Key, Value >::remove ( const Key &  key)
inline
template<class Key, class Value>
void IMap< Key, Value >::remove ( const int  index)
inline
template<class Key, class Value>
Iterator IMap< Key, Value >::replace ( const Key &  key,
const Value &  value 
)
inline
template<class Key, class Value>
int IMap< Key, Value >::size ( ) const
inline
template<class Key, class Value>
Value IMap< Key, Value >::value ( const int  index)
inline
template<class Key, class Value>
QList<Value> IMap< Key, Value >::values ( ) const
inline

Friends And Related Function Documentation

template<class Key, class Value>
friend class IMapConstIterator< Key, Value >
friend
template<class Key, class Value>
friend class IMapIterator< Key, Value >
friend

Member Data Documentation

template<class Key, class Value>
Key IMap< Key, Value >::dummyKey
private
template<class Key, class Value>
Value IMap< Key, Value >::dummyValue
private
template<class Key, class Value>
QMap<Key,Value> IMap< Key, Value >::myData
private
template<class Key, class Value>
QList<Key> IMap< Key, Value >::myKeys
private

The documentation for this class was generated from the following file: