template<typename T, template< class > class StoragePolicy = PreserveStorage, void Finalizer = standard_delete_finalizer<T>, bool finalizeOnExit = false>
class Rcpp::XPtr< T, StoragePolicy, Finalizer, finalizeOnExit >
Definition at line 61 of file XPtr.h.
template<typename T, template< class > class StoragePolicy = PreserveStorage, void Finalizer = standard_delete_finalizer<T>, bool finalizeOnExit = false>
| Rcpp::XPtr< T, StoragePolicy, Finalizer, finalizeOnExit >::XPtr |
( |
SEXP | x | ) |
|
|
inlineexplicit |
constructs a XPtr wrapping the external pointer (EXTPTRSXP SEXP)
- Parameters
-
| xp | external pointer to wrap |
Definition at line 78 of file XPtr.h.
template<typename T, template< class > class StoragePolicy = PreserveStorage, void Finalizer = standard_delete_finalizer<T>, bool finalizeOnExit = false>
| Rcpp::XPtr< T, StoragePolicy, Finalizer, finalizeOnExit >::XPtr |
( |
SEXP | x, |
|
|
SEXP | tag, |
|
|
SEXP | prot ) |
|
inlineexplicit |
constructs a XPtr wrapping the external pointer (EXTPTRSXP SEXP)
- Parameters
-
| xp | external pointer to wrap |
| tag | tag to assign to external pointer |
| prot | protected data to assign to external pointer |
Definition at line 87 of file XPtr.h.
template<typename T, template< class > class StoragePolicy = PreserveStorage, void Finalizer = standard_delete_finalizer<T>, bool finalizeOnExit = false>
| Rcpp::XPtr< T, StoragePolicy, Finalizer, finalizeOnExit >::XPtr |
( |
T * | p, |
|
|
bool | set_delete_finalizer = true, |
|
|
SEXP | tag = R_NilValue, |
|
|
SEXP | prot = R_NilValue ) |
|
inlineexplicit |
creates a new external pointer wrapping the dumb pointer p.
- Parameters
-
| p | dumb pointer to some object |
| set_delete_finalizer | if set to true, a finalizer will be registered for the external pointer. The finalizer is called when the xp is garbage collected. The finalizer is merely a call to the delete operator or the pointer so you need to make sure the pointer can be "delete" d this way (has to be a C++ object) |
Definition at line 104 of file XPtr.h.
template<typename T, template< class > class StoragePolicy = PreserveStorage, void Finalizer = standard_delete_finalizer<T>, bool finalizeOnExit = false>
| T * Rcpp::XPtr< T, StoragePolicy, Finalizer, finalizeOnExit >::get |
( |
| ) |
const |
|
inline |
template<typename T, template< class > class StoragePolicy = PreserveStorage, void Finalizer = standard_delete_finalizer<T>, bool finalizeOnExit = false>
| T & Rcpp::XPtr< T, StoragePolicy, Finalizer, finalizeOnExit >::operator* |
( |
| ) |
const |
|
inline |
Returns a reference to the object wrapped. This allows this object to look and feel like a dumb pointer to T
Definition at line 157 of file XPtr.h.
template<typename T, template< class > class StoragePolicy = PreserveStorage, void Finalizer = standard_delete_finalizer<T>, bool finalizeOnExit = false>
| T * Rcpp::XPtr< T, StoragePolicy, Finalizer, finalizeOnExit >::operator-> |
( |
| ) |
const |
|
inline |
Returns the dumb pointer. This allows to call the -> operator on this as if it was the dumb pointer
Definition at line 165 of file XPtr.h.
template<typename T, template< class > class StoragePolicy = PreserveStorage, void Finalizer = standard_delete_finalizer<T>, bool finalizeOnExit = false>
| void Rcpp::XPtr< T, StoragePolicy, Finalizer, finalizeOnExit >::release |
( |
| ) |
|
|
inline |