Bayonne2 / Common C++ 2 Framework
Public Member Functions | Private Attributes
MapIndex Class Reference

The MapIndex allows linear access into a MapTable, that otherwise could have its elements being retrieved only by key. More...

#include <object.h>

Collaboration diagram for MapIndex:
Collaboration graph
[legend]

Public Member Functions

  MapIndex ()
  Creates an empty map index (pointing to nothing). More...
 
  MapIndex (MapObject *theObject)
  Creates a map index pointing to a specific map object. More...
 
  MapIndex (const MapIndex &theIndex)
  Creates a copy of a given map index. More...
 
void *  operator* () const
  Dereference operator: the pointed object it is returned as void * for easy re-cast. More...
 
MapIndexoperator= (MapObject *theObject)
  Assignment operator to avoid implicit cast. More...
 
  Prefix increment operator, to be used in loops and such. More...
 
  Postfix increment operator, to be used in loops and such. More...
 
bool  operator== (const MapIndex &theIndex) const
  Comparison operator, between two MapIndex's. More...
 
bool  operator!= (const MapIndex &theIndex) const
 
bool  operator== (const MapObject *theObject) const
  Comparison operator, between the MapIndex and a MapObject, useful to avoid casts for sake of clearness. More...
 
bool  operator!= (const MapObject *theObject) const
 

Private Attributes

 

Detailed Description

The MapIndex allows linear access into a MapTable, that otherwise could have its elements being retrieved only by key.

It can be increased, checked and dereferenced like a pointer, by means of suitable operators.

Author
Sergio Repetto s.rep.nosp@m.etto.nosp@m.@pent.nosp@m.aeng.nosp@m.ineer.nosp@m.ing..nosp@m.it Index object to access MapTable elements

Definition at line 472 of file object.h.

Constructor & Destructor Documentation

MapIndex::MapIndex ( )
inline

Creates an empty map index (pointing to nothing).

Definition at line 481 of file object.h.

MapIndex::MapIndex ( MapObjecttheObject )
inline

Creates a map index pointing to a specific map object.

Parameters
the indexed object

Definition at line 489 of file object.h.

MapIndex::MapIndex ( const MapIndextheIndex )
inline

Creates a copy of a given map index.

Parameters
the source index object

Definition at line 497 of file object.h.

Member Function Documentation

bool MapIndex::operator!= ( const MapIndextheIndex ) const
inline

Definition at line 539 of file object.h.

bool MapIndex::operator!= ( const MapObjecttheObject ) const
inline

Definition at line 551 of file object.h.

void* MapIndex::operator* ( ) const
inline

Dereference operator: the pointed object it is returned as void * for easy re-cast.

Returns
pointer to indexed object.

Definition at line 506 of file object.h.

MapIndex& MapIndex::operator++ ( )

Prefix increment operator, to be used in loops and such.

Returns
the object itself, as changed.
MapIndex MapIndex::operator++ ( int  )
inline

Postfix increment operator, to be used in loops and such.

Returns
the object itself, as changed.

Definition at line 528 of file object.h.

MapIndex& MapIndex::operator= ( MapObjecttheObject )

Assignment operator to avoid implicit cast.

Returns
the object itself, as changed.
bool MapIndex::operator== ( const MapIndextheIndex ) const
inline

Comparison operator, between two MapIndex's.

Returns
the object itself, as changed.

Definition at line 536 of file object.h.

bool MapIndex::operator== ( const MapObjecttheObject ) const
inline

Comparison operator, between the MapIndex and a MapObject, useful to avoid casts for sake of clearness.

Returns
the object itself, as changed.

Definition at line 548 of file object.h.

Field Documentation

MapObject* MapIndex::thisObject
private

Definition at line 474 of file object.h.


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

Generated on Dec 21, 2017 for commoncpp2-1.8.1, ccrtp-1.7.2, libzrtpcpp-2.3.4, ccscript3-1.1.7, ccaudio2-1.0.0 and bayonne2-2.3.2 (after installation in /usr/local/) by   doxygen 1.8.6

AltStyle によって変換されたページ (->オリジナル) /