LOOS  v2.3.2
loos::UniqueStrings Class Reference

Class for uniquifying strings... More...

#include <UniqueStrings.hpp>

Public Member Functions

void add (const std::string &s)
 Adds a string to the unique string list.
int size (void) const
 Number of unique strings found...
__gnu_cxx::slist< std::string > strings (void) const
 Returns the raw slist of strings...
int find (const std::string &s)
 Checks to see if we've encountered this string before... More...

Detailed Description

Class for uniquifying strings...

This class uses an slist and just does a linear search to see if we've already encountered the passed string before. This probably should be updated to use a faster method in the future...

Definition at line 47 of file UniqueStrings.hpp.

Member Function Documentation

int loos::UniqueStrings::find ( const std::string &  s)

Checks to see if we've encountered this string before...

Returns an index (a unique int) representing this string. If the string is not found, returns -1.

Definition at line 66 of file UniqueStrings.hpp.

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