---
name: "qgdict"
section: "3qt"
platform: "linux"
package: "qt-doc"
version: "3:2.3.1-22"
release: "Debian 3.0 (Woody)"
platforms: ["linux"]
url: "https://new.carta.tech/qgdict"
---

# qgdict(3qt)

Internal class for implementing #include \<qgdict.h\> Inherits QCollection. Inherited by QAsciiDict, QDict, QIntDict and QPtrDict.

## NAME

QGDict - Internal class for implementing\

`#include <qgdict.h>`

Inherits QCollection.

Inherited by QAsciiDict, QDict, QIntDict and QPtrDict.

### Public Members

**virtual uint count () const (internal)**\
 **uint size () const (internal)**\
 **QCollection::Item look\_string ( const QString &** *key***, QCollection::Item, int ) (internal)**\
 **QCollection::Item look\_ascii ( const char \*** *key***, QCollection::Item, int ) (internal)**\
 **QCollection::Item look\_int ( long** *key***, QCollection::Item, int ) (internal)**\
 **QCollection::Item look\_ptr ( void \*** *key***, QCollection::Item, int ) (internal)**\
 **QDataStream& read ( QDataStream & ) (internal)**\
 **QDataStream& write ( QDataStream & ) const (internal)**\

### Protected Members

**enum KeyType { StringKey, AsciiKey, IntKey, PtrKey }**\
 **QGDict ( uint** *len***, KeyType** *kt***, bool** *cs***, bool ck ) (internal)**\
 **QGDict ( const QGDict & ) (internal)**\
 **~QGDict () (internal)**\
 **QGDict& operator= ( const QGDict & ) (internal)**\
 **bool remove\_string ( const QString &** *key***, QCollection::Item** *item***=0 ) (internal)**\
 **bool remove\_ascii ( const char \*** *key***, QCollection::Item** *item***=0 ) (internal)**\
 **bool remove\_int ( long** *key***, QCollection::Item** *item***=0 ) (internal)**\
 **bool remove\_ptr ( void \*** *key***, QCollection::Item** *item***=0 ) (internal)**\
 **QCollection::Item take\_string ( const QString & key ) (internal)**\
 **QCollection::Item take\_ascii ( const char \* key ) (internal)**\
 **QCollection::Item take\_int ( long key ) (internal)**\
 **QCollection::Item take\_ptr ( void \* key ) (internal)**\
 **virtual void clear () (internal)**\
 **void resize ( uint ) (internal)**\
 **int hashKeyString ( const QString & ) (internal)**\
 **int hashKeyAscii ( const char \* ) (internal)**\
 **void statistics () const (internal)**\
 **virtual QDataStream& read ( QDataStream &, QCollection::Item & )** \
 **virtual QDataStream& write ( QDataStream &, QCollection::Item ) const**\

## DESCRIPTION

The QGDict class is an internal class for implementing QDict template classes.

QGDict is a strictly internal class that acts as a base class for the collection classes QDict and QIntDict.

QGDict has some virtual functions that can be reimplemented to customize the subclasses.

- read() reads a collection/dictionary item from a QDataStream.

  - write() writes a collection/dictionary item to a QDataStream. Normally, you do not have to reimplement any of these functions.

  ## MEMBER FUNCTION DOCUMENTATION

## QDataStream& QGDict::read ( QDataStream & s, QCollection::Item & item ) `[virtual protected]`

Reads a collection/dictionary item from the stream *s* and returns a reference to the stream.

The default implementation sets *item* to 0.

See also write().

## QDataStream& QGDict::write ( QDataStream & s, QCollection::Item ) const `[virtual protected]`

Writes a collection/dictionary item to the stream *s* and returns a reference to the stream.

See also read().

## QGDict::QGDict ( const QGDict & dict ) `[protected]`

For internal use only.

## QGDict::QGDict ( uint len, KeyType kt, bool caseSensitive, bool copyKeys ) `[protected]`

For internal use only.

## QGDict::~QGDict () `[protected]`

For internal use only.

## void QGDict::clear () `[virtual protected]`

For internal use only.

Reimplemented from QCollection.

## uint QGDict::count () const `[virtual]`

For internal use only.

Reimplemented from QCollection.

## int QGDict::hashKeyAscii ( const char \* key ) `[protected]`

For internal use only.

## int QGDict::hashKeyString ( const QString & key ) `[protected]`

For internal use only.

## QCollection::Item QGDict::look\_ascii( const char \* key, QCollection::Item d, int op )

For internal use only.

## QCollection::Item QGDict::look\_int( long key, QCollection::Item d, int op )

For internal use only.

## QCollection::Item QGDict::look\_ptr( void \* key, QCollection::Item d, int op )

For internal use only.

## QCollection::Item QGDict::look\_string( const QString & key, QCollection::Item d, int op )

For internal use only.

## QGDict & QGDict::operator= ( const QGDict & dict ) `[protected]`

For internal use only.

## QDataStream & QGDict::read ( QDataStream & s )

For internal use only.

## bool QGDict::remove\_ascii ( const char \* key, QCollection::Item item=0 ) `[protected]`

For internal use only.

## bool QGDict::remove\_int ( long key, QCollection::Item item=0 ) `[protected]`

For internal use only.

## bool QGDict::remove\_ptr ( void \* key, QCollection::Item item=0 ) `[protected]`

For internal use only.

## bool QGDict::remove\_string ( const QString & key, QCollection::Item item=0 ) `[protected]`

For internal use only.

## void QGDict::resize ( uint newsize ) `[protected]`

For internal use only.

## uint QGDict::size () const

For internal use only.

## void QGDict::statistics () const `[protected]`

For internal use only.

## QCollection::Item QGDict::take\_ascii( const char \* key ) `[protected]`

For internal use only.

## QCollection::Item QGDict::take\_int( long key ) `[protected]`

For internal use only.

## QCollection::Item QGDict::take\_ptr( void \* key ) `[protected]`

For internal use only.

## QCollection::Item QGDict::take\_string( const QString & key ) `[protected]`

For internal use only.

## QDataStream& QGDict::write ( QDataStream & s ) const

For internal use only.

## SEE ALSO

**http://doc.trolltech.com/qgdict.html** **http://www.trolltech.com/faq/tech.html**

## COPYRIGHT

Copyright 1992-2001 Trolltech AS, http://www.trolltech.com.  See the license file included in the distribution for a complete license statement.

## AUTHOR

Generated automatically from the source code.

## BUGS

If you find a bug in Qt, please report it as described in **http://doc.trolltech.com/bughowto.html**. Good bug reports make our job much simpler. Thank you.

In case of content or formattting problems with this manual page, please report them to **qt-bugs@trolltech.com**. Please include the name of the manual page (qgdict.3qt) and the Qt version (2.3.1).
