Galois
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
galois::UnionFindNode< T > Class Template Reference

Intrusive union-find implementation. More...

#include <UnionFind.h>

Public Types

typedef UnionFindNode< T > SuperTy
 

Public Member Functions

bool isRep () const
 
T * get () const
 
const T * find () const
 
T * find ()
 
void compress ()
 Compress ONLY node to point directly to the root of the tree; nodes on path are not altered. More...
 
T * findAndCompress ()
 
T * merge (T *b)
 Lock-free merge. Returns if merge was done. More...
 

Protected Member Functions

 UnionFindNode (T *s)
 

Protected Attributes

std::atomic< T * > m_component
 

Detailed Description

template<typename T>
class galois::UnionFindNode< T >

Intrusive union-find implementation.

Users subclass this to get disjoint functionality for the subclass object.

Member Typedef Documentation

template<typename T>
typedef UnionFindNode<T> galois::UnionFindNode< T >::SuperTy

Constructor & Destructor Documentation

template<typename T>
galois::UnionFindNode< T >::UnionFindNode ( T *  s)
inlineprotected

Member Function Documentation

template<typename T>
void galois::UnionFindNode< T >::compress ( )
inline

Compress ONLY node to point directly to the root of the tree; nodes on path are not altered.

template<typename T>
const T* galois::UnionFindNode< T >::find ( ) const
inline
template<typename T>
T* galois::UnionFindNode< T >::find ( )
inline
template<typename T>
T* galois::UnionFindNode< T >::findAndCompress ( )
inline
template<typename T>
T* galois::UnionFindNode< T >::get ( void  ) const
inline
template<typename T>
bool galois::UnionFindNode< T >::isRep ( ) const
inline
template<typename T>
T* galois::UnionFindNode< T >::merge ( T *  b)
inline

Lock-free merge. Returns if merge was done.

Member Data Documentation

template<typename T>
std::atomic<T*> galois::UnionFindNode< T >::m_component
protected

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