Lucene++ - a full-featured, c++ search engine
API Documentation

- Main Page
- Related Pages
- Namespaces
- Data Structures
- Files

- Data Structures
- Class Hierarchy
- Data Fields

All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Types | Public Member Functions | Protected Attributes
Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL > Class Template Reference

Helper class for keeping Lists of Objects associated with keys. More...

`#include <MapOfSets.h>`

## Public Types

typedef HashSet< SETVALUE, SETHASH, SETEQUAL > | set_type
typedef HashMap< MAPKEY, set_type, MAPHASH, MAPEQUAL > | map_type

## Public Member Functions

| MapOfSets (map_type m)
map_type | getMap ()
int32_t | put (MAPKEY key, SETVALUE val)
| Adds val to the HashSet associated with key in the HashMap. If key is not already in the map, a new HashSet will first be created. More...
int32_t | putAll (MAPKEY key, set_type vals)
| Adds multiple vals to the HashSet associated with key in the HashMap. If key is not already in the map, a new HashSet will first be created. More...

## Protected Attributes

map_type | theMap

## Detailed Description

### template<class MAPKEY, class MAPHASH, class MAPEQUAL, class SETVALUE, class SETHASH, class SETEQUAL>
class Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >

Helper class for keeping Lists of Objects associated with keys.

## Member Typedef Documentation

template<class MAPKEY , class MAPHASH , class MAPEQUAL , class SETVALUE , class SETHASH , class SETEQUAL >

typedef HashMap<MAPKEY, set_type, MAPHASH, MAPEQUAL> Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::map_type

template<class MAPKEY , class MAPHASH , class MAPEQUAL , class SETVALUE , class SETHASH , class SETEQUAL >

typedef HashSet<SETVALUE, SETHASH, SETEQUAL> Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::set_type

## Constructor & Destructor Documentation

template<class MAPKEY , class MAPHASH , class MAPEQUAL , class SETVALUE , class SETHASH , class SETEQUAL >

Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::MapOfSets | ( | map_type | m) |  |

inline

References Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::theMap.

## Member Function Documentation

template<class MAPKEY , class MAPHASH , class MAPEQUAL , class SETVALUE , class SETHASH , class SETEQUAL >

map_type Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::getMap | ( | ) |  |

inline

Returns
  direct access to the map backing this object.

References Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::theMap.

template<class MAPKEY , class MAPHASH , class MAPEQUAL , class SETVALUE , class SETHASH , class SETEQUAL >

int32_t Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::put | ( | MAPKEY | key,
|  | SETVALUE | val
| ) |  |

inline

Adds val to the HashSet associated with key in the HashMap. If key is not already in the map, a new HashSet will first be created.

Returns
  the size of the HashSet associated with key once val is added to it.

References Lucene::HashSet< TYPE, HASH, EQUAL >::add(), Lucene::HashMap< KEY, VALUE, HASH, EQUAL >::end(), Lucene::HashMap< KEY, VALUE, HASH, EQUAL >::find(), Lucene::HashSet< TYPE, HASH, EQUAL >::newInstance(), Lucene::HashMap< KEY, VALUE, HASH, EQUAL >::put(), and Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::theMap.

template<class MAPKEY , class MAPHASH , class MAPEQUAL , class SETVALUE , class SETHASH , class SETEQUAL >

int32_t Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::putAll | ( | MAPKEY | key,
|  | set_type | vals
| ) |  |

inline

Adds multiple vals to the HashSet associated with key in the HashMap. If key is not already in the map, a new HashSet will first be created.

Returns
  the size of the HashSet associated with key once val is added to it.

References Lucene::HashSet< TYPE, HASH, EQUAL >::begin(), Lucene::HashMap< KEY, VALUE, HASH, EQUAL >::end(), Lucene::HashSet< TYPE, HASH, EQUAL >::end(), Lucene::HashMap< KEY, VALUE, HASH, EQUAL >::find(), Lucene::HashSet< TYPE, HASH, EQUAL >::newInstance(), Lucene::HashMap< KEY, VALUE, HASH, EQUAL >::put(), Lucene::HashSet< TYPE, HASH, EQUAL >::size(), and Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::theMap.

## Field Documentation

template<class MAPKEY , class MAPHASH , class MAPEQUAL , class SETVALUE , class SETHASH , class SETEQUAL >

map_type Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::theMap

protected

Referenced by Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::getMap(), Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::MapOfSets(), Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::put(), and Lucene::MapOfSets< MAPKEY, MAPHASH, MAPEQUAL, SETVALUE, SETHASH, SETEQUAL >::putAll().

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

- MapOfSets.h

clucene.sourceforge.net