Debea Library 1.4.2

stdSet Class Template Reference
[Conversion filters for store tables]

Collection filter for std::set Objects that are stored using this collection should not implement operator< using Storeable fields because they will be modified directly in std::set. More...

#include <stdset.h>

Inheritance diagram for stdSet:
Collaboration diagram for stdSet:

List of all members.


Public Member Functions

virtual void clear ()
 Remove all objects from collection.
virtual CollectionFilterIteratorcreateIterator () const
 Create new iterator for traversal.
 stdSet (std::set< T > &pSet)
 Constructor.

Detailed Description

template<typename T>
class dba::stdSet< T >

Collection filter for std::set Objects that are stored using this collection should not implement operator< using Storeable fields because they will be modified directly in std::set.

When updating object in set remember that you need to preserve dba::Storeable state. This means that you need to remove old one, update fields of old with new and readd old one again like this:

  //having a set like this
  SomeObject old, newone;
  std::set<SomeObject> objset;
  objset.insert(old);
  //update object in the set this way:
  Object old(objset.erase(objset.begin());
  dba::IdLocker l;
  old = newone;
  exset.insert(old);

Constructor & Destructor Documentation

stdSet ( std::set< T > &  pSet  ) 

Constructor.

Parameters:
pSet object that will be modified by filter


Member Function Documentation

virtual CollectionFilterIterator* createIterator (  )  const [virtual]

Create new iterator for traversal.

Returns:
new iterator instance

Implements CollectionFilterBase.


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

Documentation
Quick start
Examples

API Documentation
Class hierarchy
Member index
API Reference
Store filters
Store table macros
Back

Generated by doxygen at Fri Oct 22 23:15:47 2010