mpqc::FermionStringDenseSet< FString > Class Template Reference

Documentation

template<typename FString>
class mpqc::FermionStringDenseSet< FString >

contiguous container of strings

Note
finding strings is slow

Public Types

using ordinal_type = std::int64_t
 
typedef std::vector< std::pair< const FString, ordinal_type > > container_type
 
typedef container_type::iterator iterator
 
typedef container_type::const_iterator const_iterator
 
typedef FString value_type
 

Public Member Functions

 FermionStringDenseSet ()=default
 
 FermionStringDenseSet (const FermionStringDenseSet &)=default
 
 FermionStringDenseSet (FermionStringDenseSet &&)=default
 
FermionStringDenseSetoperator= (const FermionStringDenseSet &)=default
 
FermionStringDenseSetoperator= (FermionStringDenseSet &&)=default
 
 ~FermionStringDenseSet ()=default
 
const_iterator insert (const FString &s)
 
const_iterator insert (FString &&s)
 
const_iterator begin () const
 
const_iterator end () const
 
const_iterator cbegin () const
 
const_iterator cend () const
 
const_iterator find (const FString &str) const
 
std::optional< const_iteratorsafe_find (const FString &str) const
 
bool contains (const FString &str) const
 
size_t size () const
 
size_t bucket_count () const
 

Member Typedef Documentation

◆ const_iterator

template<typename FString >
typedef container_type::const_iterator mpqc::FermionStringDenseSet< FString >::const_iterator

◆ container_type

template<typename FString >
typedef std::vector<std::pair<const FString, ordinal_type> > mpqc::FermionStringDenseSet< FString >::container_type

instead of storing strings themselves store string-ordinal pairs to make generically interchangeable with FermionStringSparseSet

◆ iterator

template<typename FString >
typedef container_type::iterator mpqc::FermionStringDenseSet< FString >::iterator

◆ ordinal_type

template<typename FString >
using mpqc::FermionStringDenseSet< FString >::ordinal_type = std::int64_t

◆ value_type

template<typename FString >
typedef FString mpqc::FermionStringDenseSet< FString >::value_type

Constructor & Destructor Documentation

◆ FermionStringDenseSet() [1/3]

template<typename FString >
mpqc::FermionStringDenseSet< FString >::FermionStringDenseSet ( )
default

◆ FermionStringDenseSet() [2/3]

template<typename FString >
mpqc::FermionStringDenseSet< FString >::FermionStringDenseSet ( const FermionStringDenseSet< FString > &  )
default

◆ FermionStringDenseSet() [3/3]

template<typename FString >
mpqc::FermionStringDenseSet< FString >::FermionStringDenseSet ( FermionStringDenseSet< FString > &&  )
default

◆ ~FermionStringDenseSet()

template<typename FString >
mpqc::FermionStringDenseSet< FString >::~FermionStringDenseSet ( )
default

Member Function Documentation

◆ begin()

template<typename FString >
const_iterator mpqc::FermionStringDenseSet< FString >::begin ( ) const
inline

◆ bucket_count()

template<typename FString >
size_t mpqc::FermionStringDenseSet< FString >::bucket_count ( ) const
inline
Returns
the number of buckets holding the strings

◆ cbegin()

template<typename FString >
const_iterator mpqc::FermionStringDenseSet< FString >::cbegin ( ) const
inline

◆ cend()

template<typename FString >
const_iterator mpqc::FermionStringDenseSet< FString >::cend ( ) const
inline

◆ contains()

template<typename FString >
bool mpqc::FermionStringDenseSet< FString >::contains ( const FString &  str) const
inline

◆ end()

template<typename FString >
const_iterator mpqc::FermionStringDenseSet< FString >::end ( ) const
inline

◆ find()

template<typename FString >
const_iterator mpqc::FermionStringDenseSet< FString >::find ( const FString &  str) const
inline

◆ insert() [1/2]

template<typename FString >
const_iterator mpqc::FermionStringDenseSet< FString >::insert ( const FString &  s)
inline
Parameters
[in]sa nonnull string to be inserted into this
Note
asserts that s.size() matches that of the first string in this, if any
asserts that s does not have equivalent already inserted

◆ insert() [2/2]

template<typename FString >
const_iterator mpqc::FermionStringDenseSet< FString >::insert ( FString &&  s)
inline
Parameters
[in]sa nonnull string to be inserted into this
Note
asserts that s.size() matches that of the first string in this, if any
asserts that s does not have equivalent already inserted

◆ operator=() [1/2]

template<typename FString >
FermionStringDenseSet& mpqc::FermionStringDenseSet< FString >::operator= ( const FermionStringDenseSet< FString > &  )
default

◆ operator=() [2/2]

template<typename FString >
FermionStringDenseSet& mpqc::FermionStringDenseSet< FString >::operator= ( FermionStringDenseSet< FString > &&  )
default

◆ safe_find()

template<typename FString >
std::optional<const_iterator> mpqc::FermionStringDenseSet< FString >::safe_find ( const FString &  str) const
inline

◆ size()

template<typename FString >
size_t mpqc::FermionStringDenseSet< FString >::size ( ) const
inline
Returns
the number of strings in the set

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