HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
UT_StringSet Class Reference

#include <UT_StringSet.h>

+ Inheritance diagram for UT_StringSet:

Public Types

typedef Parent::key_type key_type
 
typedef Parent::value_type value_type
 
typedef Parent::hasher hasher
 
typedef Parent::key_equal key_equal
 
typedef Parent::iterator iterator
 
typedef Parent::const_iterator const_iterator
 
typedef Parent::size_type size_type
 
- Public Types inherited from UT_Set< UT_StringHolder >
typedef hboost::unordered_set
< UT_StringHolder,
hboost::hash< UT_StringHolder >
, std::equal_to
< UT_StringHolder > > 
Base
 
typedef hboost::hash
< UT_StringHolder
Hasher
 
typedef std::equal_to
< UT_StringHolder
Equal
 
typedef Base::key_type key_type
 
typedef Base::value_type value_type
 
typedef Base::hasher hasher
 
typedef Base::key_equal key_equal
 
typedef Base::iterator iterator
 
typedef Base::const_iterator const_iterator
 

Public Member Functions

 UT_StringSet ()=default
 
template<typename InputIt >
 UT_StringSet (InputIt first, InputIt last)
 Constructs a set from an iterator range. More...
 
 UT_StringSet (std::initializer_list< UT_StringHolder > init)
 Constructs a set from an initializer list. More...
 
iterator erase (const_iterator pos)
 
iterator erase (const_iterator first, const_iterator last)
 
bool contains (const UT_StringRef &ref) const
 
bool contains (const UT_StringSet &src) const
 
UT_StringSetoperator|= (const UT_StringSet &src)
 Set-wise boolean operations. More...
 
UT_StringSetoperator&= (const UT_StringSet &src)
 
UT_StringSetoperator-= (const UT_StringSet &src)
 
- Public Member Functions inherited from UT_Set< UT_StringHolder >
 UT_Set (const Hasher &hf=Hasher(), const Equal &eql=Equal())
 
 UT_Set (InputIt first, InputIt last, const Hasher &hf=Hasher(), const Equal &eql=Equal())
 
 UT_Set (const UT_StringHolder &k, const Hasher &hf=Hasher(), const Equal &eql=Equal())
 
 UT_Set (std::initializer_list< UT_StringHolder > init, const Hasher &hf=Hasher(), const Equal &eql=Equal())
 
int64 getMemoryUsage (bool inclusive) const
 
bool contains (const UT_StringHolder &key) const
 
bool contains (const UT_Set< UT_StringHolder > &src) const
 
void clear ()
 
UT_Set< UT_StringHolder,
hboost::hash< UT_StringHolder >
, std::equal_to
< UT_StringHolder > > & 
operator|= (const UT_Set< UT_StringHolder, hboost::hash< UT_StringHolder >, std::equal_to< UT_StringHolder > > &src)
 Set-wise boolean operations. More...
 
UT_Set< UT_StringHolder,
hboost::hash< UT_StringHolder >
, std::equal_to
< UT_StringHolder > > & 
operator&= (const UT_Set< UT_StringHolder, hboost::hash< UT_StringHolder >, std::equal_to< UT_StringHolder > > &src)
 
UT_Set< UT_StringHolder,
hboost::hash< UT_StringHolder >
, std::equal_to
< UT_StringHolder > > & 
operator-= (const UT_Set< UT_StringHolder, hboost::hash< UT_StringHolder >, std::equal_to< UT_StringHolder > > &src)
 

Detailed Description

UT_StringSet is a simple specialization of a UT_Set that has UT_StringHolder as its key type which allows C strings to be used. If you know that a string will not be destroyed during the set's lifetime, UTmakeUnsafeRef can be used to insert a shallow reference.

Definition at line 45 of file UT_StringSet.h.

Member Typedef Documentation

Definition at line 52 of file UT_StringSet.h.

Definition at line 54 of file UT_StringSet.h.

Definition at line 53 of file UT_StringSet.h.

Definition at line 50 of file UT_StringSet.h.

typedef Parent::size_type UT_StringSet::size_type

Definition at line 56 of file UT_StringSet.h.

Definition at line 51 of file UT_StringSet.h.

Constructor & Destructor Documentation

UT_StringSet::UT_StringSet ( )
default
template<typename InputIt >
UT_StringSet::UT_StringSet ( InputIt  first,
InputIt  last 
)
inline

Constructs a set from an iterator range.

Definition at line 62 of file UT_StringSet.h.

UT_StringSet::UT_StringSet ( std::initializer_list< UT_StringHolder init)
inline

Constructs a set from an initializer list.

Definition at line 65 of file UT_StringSet.h.

Member Function Documentation

bool UT_StringSet::contains ( const UT_StringRef ref) const
inline

Definition at line 79 of file UT_StringSet.h.

bool UT_StringSet::contains ( const UT_StringSet src) const
inline

Definition at line 82 of file UT_StringSet.h.

iterator UT_StringSet::erase ( const_iterator  pos)
inline

Definition at line 67 of file UT_StringSet.h.

iterator UT_StringSet::erase ( const_iterator  first,
const_iterator  last 
)
inline

Definition at line 69 of file UT_StringSet.h.

UT_StringSet& UT_StringSet::operator&= ( const UT_StringSet src)
inline

Definition at line 93 of file UT_StringSet.h.

UT_StringSet& UT_StringSet::operator-= ( const UT_StringSet src)
inline

Definition at line 100 of file UT_StringSet.h.

UT_StringSet& UT_StringSet::operator|= ( const UT_StringSet src)
inline

Set-wise boolean operations.

Definition at line 89 of file UT_StringSet.h.


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