Easy3D 2.6.1
Loading...
Searching...
No Matches
PointCloud::BaseHandle Class Reference

Base class for topology types (internally it is basically an index). More...

#include <easy3d/core/point_cloud.h>

Inheritance diagram for PointCloud::BaseHandle:
PointCloud::Vertex

Classes

struct  Hash
 Helper structure to be able to use std::unordered_map. More...
 

Public Member Functions

 BaseHandle (int _idx=-1)
 Constructor.
 
int idx () const
 Get the underlying index of this handle.
 
void reset ()
 Reset handle to be invalid (index = -1).
 
bool is_valid () const
 Return whether the handle is valid, i.e., the index is not equal to -1.
 
bool operator== (const BaseHandle &_rhs) const
 Are two handles equal?
 
bool operator!= (const BaseHandle &_rhs) const
 Are two handles different?
 
bool operator< (const BaseHandle &_rhs) const
 Compare operator useful for sorting handles.
 

Friends

class PointCloud
 

Detailed Description

Base class for topology types (internally it is basically an index).

See also
Vertex

Constructor & Destructor Documentation

◆ BaseHandle()

BaseHandle ( int _idx = -1)
inlineexplicit

Constructor.

Parameters
_idxThe index of the handle.

Member Function Documentation

◆ idx()

int idx ( ) const
inline

Get the underlying index of this handle.

Returns
The index of the handle.

◆ is_valid()

bool is_valid ( ) const
inline

Return whether the handle is valid, i.e., the index is not equal to -1.

Returns
True if the handle is valid, false otherwise.

◆ operator!=()

bool operator!= ( const BaseHandle & _rhs) const
inline

Are two handles different?

Parameters
_rhsThe other handle to compare.
Returns
True if the handles are different, false otherwise.

◆ operator<()

bool operator< ( const BaseHandle & _rhs) const
inline

Compare operator useful for sorting handles.

Parameters
_rhsThe other handle to compare.
Returns
True if this handle is less than the other handle, false otherwise.

◆ operator==()

bool operator== ( const BaseHandle & _rhs) const
inline

Are two handles equal?

Parameters
_rhsThe other handle to compare.
Returns
True if the handles are equal, false otherwise.

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