Rcpp Version 1.0.9
Rcpp::internal::string_proxy< RTYPE, StoragePolicy > Class Template Reference

#include <string_proxy.h>

Collaboration diagram for Rcpp::internal::string_proxy< RTYPE, StoragePolicy >:

Public Types

typedef ::Rcpp::Vector< RTYPE, StoragePolicy > VECTOR
 
typedef const char * iterator
 
typedef const char & reference
 

Public Member Functions

 string_proxy ()
 
 string_proxy (VECTOR &v, R_xlen_t index_)
 
 string_proxy (const string_proxy &other)
 
string_proxyoperator= (const string_proxy< RTYPE, StoragePolicy > &other)
 
template<template< class > class StoragePolicy2>
string_proxyoperator= (const string_proxy< RTYPE, StoragePolicy2 > &other)
 
template<template< class > class StoragePolicy2>
string_proxyoperator= (const const_string_proxy< RTYPE, StoragePolicy2 > &other)
 
string_proxyoperator= (const String &s)
 
template<typename T >
string_proxyoperator= (const std::basic_string< T > &rhs)
 
string_proxyoperator= (const char *rhs)
 
string_proxyoperator= (const wchar_t *rhs)
 
string_proxyoperator= (SEXP rhs)
 
void import (const string_proxy &other)
 
template<typename T >
string_proxyoperator+= (const T &rhs)
 
 operator SEXP () const
 
 operator char * () const
 
void swap (string_proxy &other)
 
void move (R_xlen_t n)
 
SEXP get () const
 
template<typename T >
void set (const T &x)
 
void set (SEXP x)
 
iterator begin () const
 
iterator end () const
 
R_xlen_t size () const
 
bool empty () const
 
reference operator[] (R_xlen_t n)
 
template<typename UnaryOperator >
void transform (UnaryOperator op)
 
template<typename OutputIterator , typename UnaryOperator >
void apply (OutputIterator target, UnaryOperator op)
 
template<typename UnaryOperator >
void apply (UnaryOperator op)
 
bool operator== (const char *other) const
 
bool operator!= (const char *other) const
 
template<template< class > class SP>
bool operator== (const string_proxy< STRSXP, SP > &other) const
 
template<template< class > class SP>
bool operator!= (const string_proxy< STRSXP, SP > &other) const
 
bool operator== (SEXP other) const
 
bool operator!= (SEXP other) const
 
template<typename T >
string_proxy< RTYPE, StoragePolicy > & operator+= (const T &rhs)
 
template<template< class > class StoragePolicy2>
string_proxy< RTYPE, StoragePolicy1 > & operator= (const const_string_proxy< RTYPE, StoragePolicy2 > &other)
 

Public Attributes

VECTORparent
 
R_xlen_t index
 

Static Private Attributes

static std::string buffer
 

Friends

template<int RT>
std::ostream & operator<< (std::ostream &os, const string_proxy< RT > &proxy)
 
template<int RT>
std::string operator+ (const std::string &x, const string_proxy< RT > &proxy)
 

Detailed Description

template<int RTYPE, template< class > class StoragePolicy>
class Rcpp::internal::string_proxy< RTYPE, StoragePolicy >

Definition at line 29 of file string_proxy.h.

Member Typedef Documentation

◆ iterator

template<int RTYPE, template< class > class StoragePolicy>
typedef const char* Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::iterator

Definition at line 33 of file string_proxy.h.

◆ reference

template<int RTYPE, template< class > class StoragePolicy>
typedef const char& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::reference

Definition at line 34 of file string_proxy.h.

◆ VECTOR

template<int RTYPE, template< class > class StoragePolicy>
typedef ::Rcpp::Vector<RTYPE, StoragePolicy> Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::VECTOR

Definition at line 32 of file string_proxy.h.

Constructor & Destructor Documentation

◆ string_proxy() [1/3]

template<int RTYPE, template< class > class StoragePolicy>
Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::string_proxy ( )
inline

Definition at line 36 of file string_proxy.h.

◆ string_proxy() [2/3]

template<int RTYPE, template< class > class StoragePolicy>
Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::string_proxy ( VECTOR v,
R_xlen_t  index_ 
)
inline

Creates a proxy

Parameters
vreference to the associated character vector
indexindex

Definition at line 44 of file string_proxy.h.

◆ string_proxy() [3/3]

template<int RTYPE, template< class > class StoragePolicy>
Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::string_proxy ( const string_proxy< RTYPE, StoragePolicy > &  other)
inline

Definition at line 46 of file string_proxy.h.

Member Function Documentation

◆ apply() [1/2]

template<int RTYPE, template< class > class StoragePolicy>
template<typename OutputIterator , typename UnaryOperator >
void Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::apply ( OutputIterator  target,
UnaryOperator  op 
)
inline

Definition at line 181 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin(), and Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::end().

Here is the call graph for this function:

◆ apply() [2/2]

template<int RTYPE, template< class > class StoragePolicy>
template<typename UnaryOperator >
void Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::apply ( UnaryOperator  op)
inline

Definition at line 186 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin(), and Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::end().

Here is the call graph for this function:

◆ begin()

◆ empty()

template<int RTYPE, template< class > class StoragePolicy>
bool Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::empty ( ) const
inline

Definition at line 170 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin().

Here is the call graph for this function:

◆ end()

template<int RTYPE, template< class > class StoragePolicy>
iterator Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::end ( ) const
inline

◆ get()

◆ import()

template<int RTYPE, template< class > class StoragePolicy>
void Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::import ( const string_proxy< RTYPE, StoragePolicy > &  other)
inline

◆ move()

template<int RTYPE, template< class > class StoragePolicy>
void Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::move ( R_xlen_t  n)
inline

◆ operator char *()

template<int RTYPE, template< class > class StoragePolicy>
Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator char * ( ) const
inline

rhs use. Retrieves the current value of the element this proxy refers to and convert it to a C string

Definition at line 127 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::get().

Here is the call graph for this function:

◆ operator SEXP()

template<int RTYPE, template< class > class StoragePolicy>
Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator SEXP ( ) const
inline

rhs use. Retrieves the current value of the element this proxy refers to.

Definition at line 118 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::get().

Here is the call graph for this function:

◆ operator!=() [1/3]

template<int RTYPE, template< class > class StoragePolicy>
bool Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator!= ( const char *  other) const
inline

Definition at line 193 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin().

Here is the call graph for this function:

◆ operator!=() [2/3]

template<int RTYPE, template< class > class StoragePolicy>
template<template< class > class SP>
bool Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator!= ( const string_proxy< STRSXP, SP > &  other) const
inline

Definition at line 203 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin().

Here is the call graph for this function:

◆ operator!=() [3/3]

template<int RTYPE, template< class > class StoragePolicy>
bool Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator!= ( SEXP  other) const
inline

Definition at line 211 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::get().

Here is the call graph for this function:

◆ operator+=() [1/2]

template<int RTYPE, template< class > class StoragePolicy>
template<typename T >
string_proxy<RTYPE, StoragePolicy>& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator+= ( const T &  rhs)

Definition at line 700 of file String.h.

References Rcpp::get().

Here is the call graph for this function:

◆ operator+=() [2/2]

template<int RTYPE, template< class > class StoragePolicy>
template<typename T >
string_proxy& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator+= ( const T &  rhs)

lhs use. Adds the content of the rhs proxy to the element this proxy refers to.

◆ operator=() [1/9]

template<int RTYPE, template< class > class StoragePolicy>
string_proxy& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( const char *  rhs)
inline

Definition at line 85 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::set().

Here is the call graph for this function:

◆ operator=() [2/9]

template<int RTYPE, template< class > class StoragePolicy>
template<template< class > class StoragePolicy2>
string_proxy<RTYPE, StoragePolicy1>& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( const const_string_proxy< RTYPE, StoragePolicy2 > &  other)

Definition at line 174 of file const_string_proxy.h.

References Rcpp::internal::const_string_proxy< RTYPE, StoragePolicy >::get().

Here is the call graph for this function:

◆ operator=() [3/9]

template<int RTYPE, template< class > class StoragePolicy>
template<template< class > class StoragePolicy2>
string_proxy& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( const const_string_proxy< RTYPE, StoragePolicy2 > &  other)

◆ operator=() [4/9]

template<int RTYPE, template< class > class StoragePolicy>
template<typename T >
string_proxy& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( const std::basic_string< T > &  rhs)
inline

lhs use. Assigns the value of the referred element of the character vector

Parameters
rhsnew content for the element referred by this proxy

Definition at line 80 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::set().

Here is the call graph for this function:

◆ operator=() [5/9]

template<int RTYPE, template< class > class StoragePolicy>
string_proxy< RTYPE, StoragePolicy > & Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( const String s)

Definition at line 682 of file String.h.

References Rcpp::String::get_sexp().

Here is the call graph for this function:

◆ operator=() [6/9]

template<int RTYPE, template< class > class StoragePolicy>
string_proxy& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( const string_proxy< RTYPE, StoragePolicy > &  other)
inline

lhs use. Assign the value of the referred element to the current content of the element referred by the rhs proxy

Parameters
rhsanother proxy, possibly from another vector

Definition at line 57 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::get(), and Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::set().

Here is the call graph for this function:

◆ operator=() [7/9]

template<int RTYPE, template< class > class StoragePolicy>
template<template< class > class StoragePolicy2>
string_proxy& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( const string_proxy< RTYPE, StoragePolicy2 > &  other)
inline

Definition at line 63 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::get(), and Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::set().

Here is the call graph for this function:

◆ operator=() [8/9]

template<int RTYPE, template< class > class StoragePolicy>
string_proxy& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( const wchar_t *  rhs)
inline

Definition at line 90 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::set().

Here is the call graph for this function:

◆ operator=() [9/9]

template<int RTYPE, template< class > class StoragePolicy>
string_proxy& Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator= ( SEXP  rhs)
inline

Definition at line 96 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::set().

Here is the call graph for this function:

◆ operator==() [1/3]

template<int RTYPE, template< class > class StoragePolicy>
bool Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator== ( const char *  other) const
inline

Definition at line 190 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin().

Here is the call graph for this function:

◆ operator==() [2/3]

template<int RTYPE, template< class > class StoragePolicy>
template<template< class > class SP>
bool Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator== ( const string_proxy< STRSXP, SP > &  other) const
inline

Definition at line 198 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin().

Here is the call graph for this function:

◆ operator==() [3/3]

template<int RTYPE, template< class > class StoragePolicy>
bool Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator== ( SEXP  other) const
inline

Definition at line 207 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::get().

Here is the call graph for this function:

◆ operator[]()

template<int RTYPE, template< class > class StoragePolicy>
reference Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::operator[] ( R_xlen_t  n)
inline

Definition at line 171 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin().

Here is the call graph for this function:

◆ set() [1/2]

template<int RTYPE, template< class > class StoragePolicy>
template<typename T >
void Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::set ( const T &  x)
inline

◆ set() [2/2]

template<int RTYPE, template< class > class StoragePolicy>
void Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::set ( SEXP  x)
inline

◆ size()

template<int RTYPE, template< class > class StoragePolicy>
R_xlen_t Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::size ( ) const
inline

Definition at line 169 of file string_proxy.h.

References Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::begin().

Referenced by Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::end().

Here is the call graph for this function:

◆ swap()

template<int RTYPE, template< class > class StoragePolicy>
void Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::swap ( string_proxy< RTYPE, StoragePolicy > &  other)
inline

◆ transform()

template<int RTYPE, template< class > class StoragePolicy>
template<typename UnaryOperator >
void Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::transform ( UnaryOperator  op)
inline

Friends And Related Function Documentation

◆ operator+

template<int RTYPE, template< class > class StoragePolicy>
template<int RT>
std::string operator+ ( const std::string &  x,
const string_proxy< RT > &  proxy 
)
friend

◆ operator<<

template<int RTYPE, template< class > class StoragePolicy>
template<int RT>
std::ostream& operator<< ( std::ostream &  os,
const string_proxy< RT > &  proxy 
)
friend

Prints the element this proxy refers to to an output stream

Member Data Documentation

◆ buffer

template<int RTYPE, template< class > class StoragePolicy>
std::string Rcpp::internal::string_proxy< RTYPE, StoragePolicy >::buffer
staticprivate

◆ index

◆ parent


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