Rcpp Version 1.0.9
Rcpp::sugar::IndexHash< RTYPE > Class Template Reference

#include <IndexHash.h>

Public Types

typedef traits::storage_type< RTYPE >::type STORAGE
 
typedef Vector< RTYPE > VECTOR
 

Public Member Functions

 IndexHash (SEXP table)
 
IndexHashfill ()
 
LogicalVector fill_and_get_duplicated ()
 
template<typename T >
SEXP lookup (const T &vec) const
 
SEXP lookup (const VECTOR &vec) const
 
bool contains (STORAGE val) const
 
int size () const
 
Vector< RTYPE > keys () const
 
template<typename T >
SEXP lookup__impl (const T &vec, int n_) const
 
SEXP get_profile_data ()
 
bool not_equal (const STORAGE &lhs, const STORAGE &rhs)
 
bool add_value (int i)
 
uint32_t get_index (STORAGE value) const
 
uint32_t get_addr (STORAGE value) const
 
uint32_t get_addr (int value) const
 
uint32_t get_addr (double val) const
 
uint32_t get_addr (SEXP value) const
 

Public Attributes

int n
 
int m
 
int k
 
STORAGEsrc
 
int size_
 
int * data
 

Detailed Description

template<int RTYPE>
class Rcpp::sugar::IndexHash< RTYPE >

Definition at line 49 of file IndexHash.h.

Member Typedef Documentation

◆ STORAGE

template<int RTYPE>
typedef traits::storage_type<RTYPE>::type Rcpp::sugar::IndexHash< RTYPE >::STORAGE

Definition at line 51 of file IndexHash.h.

◆ VECTOR

template<int RTYPE>
typedef Vector<RTYPE> Rcpp::sugar::IndexHash< RTYPE >::VECTOR

Definition at line 52 of file IndexHash.h.

Constructor & Destructor Documentation

◆ IndexHash()

Member Function Documentation

◆ add_value()

◆ contains()

template<int RTYPE>
bool Rcpp::sugar::IndexHash< RTYPE >::contains ( STORAGE  val) const
inline

Definition at line 101 of file IndexHash.h.

References Rcpp::sugar::IndexHash< RTYPE >::get_index().

Here is the call graph for this function:

◆ fill()

template<int RTYPE>
IndexHash& Rcpp::sugar::IndexHash< RTYPE >::fill ( )
inline

◆ fill_and_get_duplicated()

template<int RTYPE>
LogicalVector Rcpp::sugar::IndexHash< RTYPE >::fill_and_get_duplicated ( )
inline

Definition at line 84 of file IndexHash.h.

References Rcpp::sugar::IndexHash< RTYPE >::add_value(), Rcpp::sugar::IndexHash< RTYPE >::n, and Rcpp::no_init().

Referenced by Rcpp::duplicated().

Here is the call graph for this function:

◆ get_addr() [1/4]

uint32_t Rcpp::sugar::IndexHash< REALSXP >::get_addr ( double  val) const
inline

Definition at line 207 of file IndexHash.h.

References RCPP_HASH.

◆ get_addr() [2/4]

uint32_t Rcpp::sugar::IndexHash< INTSXP >::get_addr ( int  value) const
inline

Definition at line 203 of file IndexHash.h.

References RCPP_HASH.

◆ get_addr() [3/4]

uint32_t Rcpp::sugar::IndexHash< STRSXP >::get_addr ( SEXP  value) const
inline

Definition at line 224 of file IndexHash.h.

References RCPP_HASH.

◆ get_addr() [4/4]

template<int RTYPE>
uint32_t Rcpp::sugar::IndexHash< RTYPE >::get_addr ( STORAGE  value) const

◆ get_index()

template<int RTYPE>
uint32_t Rcpp::sugar::IndexHash< RTYPE >::get_index ( STORAGE  value) const
inline

◆ get_profile_data()

template<int RTYPE>
SEXP Rcpp::sugar::IndexHash< RTYPE >::get_profile_data ( )
inline

Definition at line 154 of file IndexHash.h.

References Rcpp::wrap().

Here is the call graph for this function:

◆ keys()

template<int RTYPE>
Vector<RTYPE> Rcpp::sugar::IndexHash< RTYPE >::keys ( ) const
inline

Definition at line 110 of file IndexHash.h.

References Rcpp::sugar::IndexHash< RTYPE >::data, Rcpp::no_init(), Rcpp::sugar::IndexHash< RTYPE >::size_, and Rcpp::sugar::IndexHash< RTYPE >::src.

Referenced by Rcpp::unique().

Here is the call graph for this function:

◆ lookup() [1/2]

template<int RTYPE>
template<typename T >
SEXP Rcpp::sugar::IndexHash< RTYPE >::lookup ( const T &  vec) const
inline

Definition at line 92 of file IndexHash.h.

References Rcpp::sugar::IndexHash< RTYPE >::lookup__impl().

Referenced by Rcpp::sugar::IndexHash< RTYPE >::lookup__impl(), and Rcpp::match().

Here is the call graph for this function:

◆ lookup() [2/2]

template<int RTYPE>
SEXP Rcpp::sugar::IndexHash< RTYPE >::lookup ( const VECTOR vec) const
inline

◆ lookup__impl()

template<int RTYPE>
template<typename T >
SEXP Rcpp::sugar::IndexHash< RTYPE >::lookup__impl ( const T &  vec,
int  n_ 
) const
inline

◆ not_equal()

template<int RTYPE>
bool Rcpp::sugar::IndexHash< RTYPE >::not_equal ( const STORAGE lhs,
const STORAGE rhs 
)
inline

Definition at line 162 of file IndexHash.h.

Referenced by Rcpp::sugar::IndexHash< RTYPE >::add_value().

◆ size()

template<int RTYPE>
int Rcpp::sugar::IndexHash< RTYPE >::size ( ) const
inline

Definition at line 105 of file IndexHash.h.

References Rcpp::sugar::IndexHash< RTYPE >::size_.

Member Data Documentation

◆ data

◆ k

template<int RTYPE>
int Rcpp::sugar::IndexHash< RTYPE >::k

Definition at line 118 of file IndexHash.h.

Referenced by Rcpp::sugar::IndexHash< RTYPE >::IndexHash().

◆ m

◆ n

◆ size_

◆ src


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