cprover
union_find< T > Class Template Referencefinal

#include <union_find.h>

+ Inheritance diagram for union_find< T >:
+ Collaboration diagram for union_find< T >:

Public Types

typedef numbering_typet::size_type size_type
 
typedef numbering_typet::iterator iterator
 
typedef numbering_typet::const_iterator const_iterator
 

Public Member Functions

bool make_union (const T &a, const T &b)
 
bool make_union (typename numbering< T >::const_iterator it_a, typename numbering< T >::const_iterator it_b)
 
bool same_set (const T &a, const T &b) const
 
bool same_set (typename numbering< T >::const_iterator it_a, typename numbering< T >::const_iterator it_b) const
 
const T & find (typename numbering< T >::const_iterator it) const
 
const T & find (const T &a)
 
size_type find_number (typename numbering< T >::const_iterator it) const
 
size_type find_number (size_type a) const
 
size_type find_number (const T &a)
 
bool is_root_number (size_type a) const
 
bool is_root (const T &a) const
 
bool is_root (typename numbering< T >::const_iterator it) const
 
size_type number (const T &a)
 
void clear ()
 
void isolate (typename numbering< T >::const_iterator it)
 
void isolate (const T &a)
 
optionalt< number_typeget_number (const T &a) const
 
size_t size () const
 
T & operator[] (size_type t)
 
const T & operator[] (size_type t) const
 
iterator begin ()
 
const_iterator begin () const
 
const_iterator cbegin () const
 
iterator end ()
 
const_iterator end () const
 
const_iterator cend () const
 

Protected Types

typedef numbering< T > subt
 

Protected Attributes

unsigned_union_find uuf
 

Private Types

typedef numbering< T > numbering_typet
 
typedef numbering_typet::number_type number_type
 

Private Attributes

numbering_typet numbers
 

Detailed Description

template<typename T>
class union_find< T >

Definition at line 137 of file union_find.h.

Member Typedef Documentation

◆ const_iterator

template<typename T >
typedef numbering_typet::const_iterator union_find< T >::const_iterator

Definition at line 151 of file union_find.h.

◆ iterator

template<typename T >
typedef numbering_typet::iterator union_find< T >::iterator

Definition at line 149 of file union_find.h.

◆ number_type

template<typename T >
typedef numbering_typet::number_type union_find< T >::number_type
private

Definition at line 143 of file union_find.h.

◆ numbering_typet

template<typename T >
typedef numbering<T> union_find< T >::numbering_typet
private

Definition at line 139 of file union_find.h.

◆ size_type

template<typename T >
typedef numbering_typet::size_type union_find< T >::size_type

Definition at line 147 of file union_find.h.

◆ subt

template<typename T >
typedef numbering<T> union_find< T >::subt
protected

Definition at line 284 of file union_find.h.

Member Function Documentation

◆ begin() [1/2]

template<typename T >
iterator union_find< T >::begin ( )
inline

Definition at line 274 of file union_find.h.

◆ begin() [2/2]

template<typename T >
const_iterator union_find< T >::begin ( ) const
inline

Definition at line 275 of file union_find.h.

◆ cbegin()

template<typename T >
const_iterator union_find< T >::cbegin ( ) const
inline

Definition at line 276 of file union_find.h.

◆ cend()

template<typename T >
const_iterator union_find< T >::cend ( ) const
inline

Definition at line 280 of file union_find.h.

◆ clear()

template<typename T >
void union_find< T >::clear ( void  )
inline

Definition at line 248 of file union_find.h.

◆ end() [1/2]

template<typename T >
iterator union_find< T >::end ( )
inline

Definition at line 278 of file union_find.h.

◆ end() [2/2]

template<typename T >
const_iterator union_find< T >::end ( ) const
inline

Definition at line 279 of file union_find.h.

◆ find() [1/2]

template<typename T >
const T& union_find< T >::find ( const T &  a)
inline

Definition at line 197 of file union_find.h.

◆ find() [2/2]

template<typename T >
const T& union_find< T >::find ( typename numbering< T >::const_iterator  it) const
inline

Definition at line 192 of file union_find.h.

◆ find_number() [1/3]

template<typename T >
size_type union_find< T >::find_number ( const T &  a)
inline

Definition at line 212 of file union_find.h.

◆ find_number() [2/3]

template<typename T >
size_type union_find< T >::find_number ( size_type  a) const
inline

Definition at line 207 of file union_find.h.

◆ find_number() [3/3]

template<typename T >
size_type union_find< T >::find_number ( typename numbering< T >::const_iterator  it) const
inline

Definition at line 202 of file union_find.h.

◆ get_number()

template<typename T >
optionalt<number_type> union_find< T >::get_number ( const T &  a) const
inline

Definition at line 264 of file union_find.h.

◆ is_root() [1/2]

template<typename T >
bool union_find< T >::is_root ( const T &  a) const
inline

Definition at line 222 of file union_find.h.

◆ is_root() [2/2]

template<typename T >
bool union_find< T >::is_root ( typename numbering< T >::const_iterator  it) const
inline

Definition at line 231 of file union_find.h.

◆ is_root_number()

template<typename T >
bool union_find< T >::is_root_number ( size_type  a) const
inline

Definition at line 217 of file union_find.h.

◆ isolate() [1/2]

template<typename T >
void union_find< T >::isolate ( const T &  a)
inline

Definition at line 259 of file union_find.h.

◆ isolate() [2/2]

template<typename T >
void union_find< T >::isolate ( typename numbering< T >::const_iterator  it)
inline

Definition at line 254 of file union_find.h.

◆ make_union() [1/2]

template<typename T >
bool union_find< T >::make_union ( const T &  a,
const T &  b 
)
inline

Definition at line 154 of file union_find.h.

◆ make_union() [2/2]

template<typename T >
bool union_find< T >::make_union ( typename numbering< T >::const_iterator  it_a,
typename numbering< T >::const_iterator  it_b 
)
inline

Definition at line 163 of file union_find.h.

◆ number()

template<typename T >
size_type union_find< T >::number ( const T &  a)
inline

Definition at line 236 of file union_find.h.

◆ operator[]() [1/2]

template<typename T >
T& union_find< T >::operator[] ( size_type  t)
inline

Definition at line 271 of file union_find.h.

◆ operator[]() [2/2]

template<typename T >
const T& union_find< T >::operator[] ( size_type  t) const
inline

Definition at line 272 of file union_find.h.

◆ same_set() [1/2]

template<typename T >
bool union_find< T >::same_set ( const T &  a,
const T &  b 
) const
inline

Definition at line 173 of file union_find.h.

◆ same_set() [2/2]

template<typename T >
bool union_find< T >::same_set ( typename numbering< T >::const_iterator  it_a,
typename numbering< T >::const_iterator  it_b 
) const
inline

Definition at line 186 of file union_find.h.

◆ size()

template<typename T >
size_t union_find< T >::size ( ) const
inline

Definition at line 269 of file union_find.h.

Member Data Documentation

◆ numbers

template<typename T >
numbering_typet union_find< T >::numbers
private

Definition at line 140 of file union_find.h.

◆ uuf

template<typename T >
unsigned_union_find union_find< T >::uuf
protected

Definition at line 283 of file union_find.h.


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