OnixS C++ CME MDP Premium Market Data Handler 5.10.3
Users' manual and API documentation
Loading...
Searching...
No Matches
TinyStrSet Class Reference

#include <OnixS/CME/MDH/TinySet.h>

Public Types

typedef Messaging::StrRef Item
typedef TinyStrSetIterator ConstIterator

Public Member Functions

 TinyStrSet ()
 TinyStrSet (size_t capacity)
 TinyStrSet (const TinyStrSet &other)
 ~TinyStrSet ()
bool empty () const
size_t size () const
void reserve (size_t capacity)
ConstIterator begin () const
ConstIterator end () const
ConstIterator find (const Item &item) const
bool insert (const Item &item)
bool erase (const Item &item)
void clear ()
void swap (TinyStrSet &other)

Detailed Description

Implements TinySet for StrRef class.

In contrast to TinySet<StrRef> instantiation, given class allocates space for content being referenced by StrRef instances inserted into the given set thus making content safe for referencing.

Definition at line 241 of file TinySet.h.

Member Typedef Documentation

◆ ConstIterator

Aliases iterator type.

Definition at line 248 of file TinySet.h.

◆ Item

Items of collection.

Definition at line 245 of file TinySet.h.

Constructor & Destructor Documentation

◆ TinyStrSet() [1/3]

TinyStrSet ( )
inline

Initializes the empty set.

Definition at line 251 of file TinySet.h.

◆ TinyStrSet() [2/3]

TinyStrSet ( size_t capacity)
inlineexplicit

Initializes the empty set capacious enough to store the given number of items.

Definition at line 255 of file TinySet.h.

◆ TinyStrSet() [3/3]

TinyStrSet ( const TinyStrSet & other)
inline

Initializes as a copy of the other instance.

Definition at line 261 of file TinySet.h.

◆ ~TinyStrSet()

~TinyStrSet ( )
inline

Destructs the internal storage.

Definition at line 267 of file TinySet.h.

Member Function Documentation

◆ begin()

ConstIterator begin ( ) const
inline

Provides iterating facilities.

Definition at line 289 of file TinySet.h.

◆ clear()

void clear ( )
inline

Brings the set to the blank (empty) state.

Definition at line 344 of file TinySet.h.

◆ empty()

bool empty ( ) const
inline

Indicates whether the set is empty.

Definition at line 270 of file TinySet.h.

◆ end()

ConstIterator end ( ) const
inline

Provides iterating facilities.

Definition at line 295 of file TinySet.h.

◆ erase()

bool erase ( const Item & item)
inline

Removes the given item from the set.

Returned value indicates whether item was actually erased.

Definition at line 331 of file TinySet.h.

◆ find()

ConstIterator find ( const Item & item) const
inline

Looks for the given item and returns iterator pointing to the found entry or to nowhere.

Definition at line 302 of file TinySet.h.

◆ insert()

bool insert ( const Item & item)
inline

Inserts the given item into the set.

Content referenced by the item being inserted is copied into the internal storage.

Returned value indicates whether the item was actually inserted.

Definition at line 315 of file TinySet.h.

◆ reserve()

void reserve ( size_t capacity)
inline

Makes the internal storage capacious enough to store the given number of items.

Definition at line 283 of file TinySet.h.

◆ size()

size_t size ( ) const
inline

Returns the number of items in the set.

Definition at line 276 of file TinySet.h.

◆ swap()

void swap ( TinyStrSet & other)
inline

Exchanges content with the other instance.

Definition at line 350 of file TinySet.h.