Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Private Attributes | List of all members
re2::StringPiece Class Reference

#include <stringpiece.h>

Public Types

typedef std::reverse_iterator< const_iteratorconst_reverse_iterator
 
typedef std::reverse_iterator< const_iteratorconst_reverse_iterator
 
typedef ptrdiff_t difference_type
 
typedef ptrdiff_t difference_type
 
typedef const_iterator iterator
 
typedef const_iterator iterator
 
typedef char * pointer
 
typedef char * pointer
 
typedef char & reference
 
typedef char & reference
 
typedef const_reverse_iterator reverse_iterator
 
typedef const_reverse_iterator reverse_iterator
 
typedef size_t size_type
 
typedef size_t size_type
 
typedef std::char_traits< char > traits_type
 
typedef std::char_traits< char > traits_type
 
typedef char value_type
 
typedef char value_type
 

Public Member Functions

void AppendToString (std::string *target) const
 
void AppendToString (std::string *target) const
 
std::string as_string () const
 
std::string as_string () const
 
const_iterator begin () const
 
const_iterator begin () const
 
int compare (const StringPiece &x) const
 
int compare (const StringPiece &x) const
 
bool contains (const StringPiece &s) const
 
bool contains (const StringPiece &s) const
 
size_type copy (char *buf, size_type n, size_type pos=0) const
 
size_type copy (char *buf, size_type n, size_type pos=0) const
 
void CopyToString (std::string *target) const
 
void CopyToString (std::string *target) const
 
const_pointer data () const
 
const_pointer data () const
 
bool empty () const
 
bool empty () const
 
const_iterator end () const
 
const_iterator end () const
 
bool ends_with (const StringPiece &x) const
 
bool ends_with (const StringPiece &x) const
 
size_type find (char c, size_type pos=0) const
 
size_type find (char c, size_type pos=0) const
 
size_type find (const StringPiece &s, size_type pos=0) const
 
size_type find (const StringPiece &s, size_type pos=0) const
 
size_type length () const
 
size_type length () const
 
template<typename A >
 operator std::basic_string< char, traits_type, A > () const
 
template<typename A >
 operator std::basic_string< char, traits_type, A > () const
 
const_reference operator[] (size_type i) const
 
const_reference operator[] (size_type i) const
 
const_reverse_iterator rbegin () const
 
const_reverse_iterator rbegin () const
 
void remove_prefix (size_type n)
 
void remove_prefix (size_type n)
 
void remove_suffix (size_type n)
 
void remove_suffix (size_type n)
 
const_reverse_iterator rend () const
 
const_reverse_iterator rend () const
 
size_type rfind (char c, size_type pos=npos) const
 
size_type rfind (char c, size_type pos=npos) const
 
size_type rfind (const StringPiece &s, size_type pos=npos) const
 
size_type rfind (const StringPiece &s, size_type pos=npos) const
 
void set (const char *str)
 
void set (const char *str)
 
void set (const char *str, size_type len)
 
void set (const char *str, size_type len)
 
size_type size () const
 
size_type size () const
 
bool starts_with (const StringPiece &x) const
 
bool starts_with (const StringPiece &x) const
 
 StringPiece ()
 
 StringPiece ()
 
 StringPiece (const char *str)
 
 StringPiece (const char *str)
 
 StringPiece (const char *str, size_type len)
 
 StringPiece (const char *str, size_type len)
 
 StringPiece (const std::string &str)
 
 StringPiece (const std::string &str)
 
StringPiece substr (size_type pos=0, size_type n=npos) const
 
StringPiece substr (size_type pos=0, size_type n=npos) const
 
std::string ToString () const
 
std::string ToString () const
 

Public Attributes

const typedef char * const_iterator
 
const typedef char * const_pointer
 
const typedef char & const_reference
 

Static Public Attributes

static const size_type npos = static_cast<size_type>(-1)
 

Private Attributes

const_pointer data_
 
size_type size_
 

Detailed Description

Definition at line 39 of file bloaty/third_party/re2/re2/stringpiece.h.

Member Typedef Documentation

◆ const_reverse_iterator [1/2]

Definition at line 49 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ const_reverse_iterator [2/2]

Definition at line 49 of file re2/re2/stringpiece.h.

◆ difference_type [1/2]

Definition at line 52 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ difference_type [2/2]

Definition at line 52 of file re2/re2/stringpiece.h.

◆ iterator [1/2]

Definition at line 48 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ iterator [2/2]

Definition at line 48 of file re2/re2/stringpiece.h.

◆ pointer [1/2]

Definition at line 43 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ pointer [2/2]

Definition at line 43 of file re2/re2/stringpiece.h.

◆ reference [1/2]

Definition at line 45 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ reference [2/2]

Definition at line 45 of file re2/re2/stringpiece.h.

◆ reverse_iterator [1/2]

Definition at line 50 of file re2/re2/stringpiece.h.

◆ reverse_iterator [2/2]

Definition at line 50 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ size_type [1/2]

Definition at line 51 of file re2/re2/stringpiece.h.

◆ size_type [2/2]

Definition at line 51 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ traits_type [1/2]

typedef std::char_traits<char> re2::StringPiece::traits_type

Definition at line 41 of file re2/re2/stringpiece.h.

◆ traits_type [2/2]

typedef std::char_traits<char> re2::StringPiece::traits_type

Definition at line 41 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ value_type [1/2]

Definition at line 42 of file re2/re2/stringpiece.h.

◆ value_type [2/2]

Definition at line 42 of file bloaty/third_party/re2/re2/stringpiece.h.

Constructor & Destructor Documentation

◆ StringPiece() [1/8]

re2::StringPiece::StringPiece ( )
inline

Definition at line 58 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ StringPiece() [2/8]

re2::StringPiece::StringPiece ( const std::string &  str)
inline

Definition at line 64 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ StringPiece() [3/8]

re2::StringPiece::StringPiece ( const char *  str)
inline

Definition at line 66 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ StringPiece() [4/8]

re2::StringPiece::StringPiece ( const char *  str,
size_type  len 
)
inline

Definition at line 68 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ StringPiece() [5/8]

re2::StringPiece::StringPiece ( )
inline

Definition at line 58 of file re2/re2/stringpiece.h.

◆ StringPiece() [6/8]

re2::StringPiece::StringPiece ( const std::string &  str)
inline

Definition at line 64 of file re2/re2/stringpiece.h.

◆ StringPiece() [7/8]

re2::StringPiece::StringPiece ( const char *  str)
inline

Definition at line 66 of file re2/re2/stringpiece.h.

◆ StringPiece() [8/8]

re2::StringPiece::StringPiece ( const char *  str,
size_type  len 
)
inline

Definition at line 68 of file re2/re2/stringpiece.h.

Member Function Documentation

◆ AppendToString() [1/2]

void re2::StringPiece::AppendToString ( std::string *  target) const
inline

Definition at line 130 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ AppendToString() [2/2]

void re2::StringPiece::AppendToString ( std::string *  target) const
inline

Definition at line 130 of file re2/re2/stringpiece.h.

◆ as_string() [1/2]

std::string re2::StringPiece::as_string ( ) const
inline

Definition at line 113 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ as_string() [2/2]

std::string re2::StringPiece::as_string ( ) const
inline

Definition at line 113 of file re2/re2/stringpiece.h.

◆ begin() [1/2]

const_iterator re2::StringPiece::begin ( ) const
inline

Definition at line 71 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ begin() [2/2]

const_iterator re2::StringPiece::begin ( ) const
inline

Definition at line 71 of file re2/re2/stringpiece.h.

◆ compare() [1/2]

int re2::StringPiece::compare ( const StringPiece x) const
inline

Definition at line 137 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ compare() [2/2]

int re2::StringPiece::compare ( const StringPiece x) const
inline

Definition at line 137 of file re2/re2/stringpiece.h.

◆ contains() [1/2]

bool re2::StringPiece::contains ( const StringPiece s) const
inline

Definition at line 162 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ contains() [2/2]

bool re2::StringPiece::contains ( const StringPiece s) const
inline

Definition at line 162 of file re2/re2/stringpiece.h.

◆ copy() [1/2]

StringPiece::size_type re2::StringPiece::copy ( char *  buf,
size_type  n,
size_type  pos = 0 
) const

Definition at line 15 of file bloaty/third_party/re2/re2/stringpiece.cc.

◆ copy() [2/2]

size_type re2::StringPiece::copy ( char *  buf,
size_type  n,
size_type  pos = 0 
) const

◆ CopyToString() [1/2]

void re2::StringPiece::CopyToString ( std::string *  target) const
inline

Definition at line 126 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ CopyToString() [2/2]

void re2::StringPiece::CopyToString ( std::string *  target) const
inline

Definition at line 126 of file re2/re2/stringpiece.h.

◆ data() [1/2]

const_pointer re2::StringPiece::data ( ) const
inline

Definition at line 85 of file re2/re2/stringpiece.h.

◆ data() [2/2]

const_pointer re2::StringPiece::data ( ) const
inline

Definition at line 85 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ empty() [1/2]

bool re2::StringPiece::empty ( ) const
inline

Definition at line 82 of file re2/re2/stringpiece.h.

◆ empty() [2/2]

bool re2::StringPiece::empty ( ) const
inline

Definition at line 82 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ end() [1/2]

const_iterator re2::StringPiece::end ( ) const
inline

Definition at line 72 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ end() [2/2]

const_iterator re2::StringPiece::end ( ) const
inline

Definition at line 72 of file re2/re2/stringpiece.h.

◆ ends_with() [1/2]

bool re2::StringPiece::ends_with ( const StringPiece x) const
inline

Definition at line 156 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ ends_with() [2/2]

bool re2::StringPiece::ends_with ( const StringPiece x) const
inline

Definition at line 156 of file re2/re2/stringpiece.h.

◆ find() [1/4]

StringPiece::size_type re2::StringPiece::find ( char  c,
size_type  pos = 0 
) const

Definition at line 37 of file bloaty/third_party/re2/re2/stringpiece.cc.

◆ find() [2/4]

size_type re2::StringPiece::find ( char  c,
size_type  pos = 0 
) const

◆ find() [3/4]

StringPiece::size_type re2::StringPiece::find ( const StringPiece s,
size_type  pos = 0 
) const

Definition at line 28 of file bloaty/third_party/re2/re2/stringpiece.cc.

◆ find() [4/4]

size_type re2::StringPiece::find ( const StringPiece s,
size_type  pos = 0 
) const

◆ length() [1/2]

size_type re2::StringPiece::length ( ) const
inline

Definition at line 81 of file re2/re2/stringpiece.h.

◆ length() [2/2]

size_type re2::StringPiece::length ( ) const
inline

Definition at line 81 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ operator std::basic_string< char, traits_type, A >() [1/2]

template<typename A >
re2::StringPiece::operator std::basic_string< char, traits_type, A > ( ) const
inlineexplicit

Definition at line 108 of file re2/re2/stringpiece.h.

◆ operator std::basic_string< char, traits_type, A >() [2/2]

template<typename A >
re2::StringPiece::operator std::basic_string< char, traits_type, A > ( ) const
inlineexplicit

Definition at line 108 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ operator[]() [1/2]

const_reference re2::StringPiece::operator[] ( size_type  i) const
inline

Definition at line 84 of file re2/re2/stringpiece.h.

◆ operator[]() [2/2]

const_reference re2::StringPiece::operator[] ( size_type  i) const
inline

Definition at line 84 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ rbegin() [1/2]

const_reverse_iterator re2::StringPiece::rbegin ( ) const
inline

Definition at line 73 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ rbegin() [2/2]

const_reverse_iterator re2::StringPiece::rbegin ( ) const
inline

Definition at line 73 of file re2/re2/stringpiece.h.

◆ remove_prefix() [1/2]

void re2::StringPiece::remove_prefix ( size_type  n)
inline

Definition at line 87 of file re2/re2/stringpiece.h.

◆ remove_prefix() [2/2]

void re2::StringPiece::remove_prefix ( size_type  n)
inline

Definition at line 87 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ remove_suffix() [1/2]

void re2::StringPiece::remove_suffix ( size_type  n)
inline

Definition at line 92 of file re2/re2/stringpiece.h.

◆ remove_suffix() [2/2]

void re2::StringPiece::remove_suffix ( size_type  n)
inline

Definition at line 92 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ rend() [1/2]

const_reverse_iterator re2::StringPiece::rend ( ) const
inline

Definition at line 76 of file re2/re2/stringpiece.h.

◆ rend() [2/2]

const_reverse_iterator re2::StringPiece::rend ( ) const
inline

Definition at line 76 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ rfind() [1/4]

size_type re2::StringPiece::rfind ( char  c,
size_type  pos = npos 
) const

◆ rfind() [2/4]

StringPiece::size_type re2::StringPiece::rfind ( char  c,
size_type  pos = npos 
) const

Definition at line 52 of file bloaty/third_party/re2/re2/stringpiece.cc.

◆ rfind() [3/4]

size_type re2::StringPiece::rfind ( const StringPiece s,
size_type  pos = npos 
) const

◆ rfind() [4/4]

StringPiece::size_type re2::StringPiece::rfind ( const StringPiece s,
size_type  pos = npos 
) const

Definition at line 43 of file bloaty/third_party/re2/re2/stringpiece.cc.

◆ set() [1/4]

void re2::StringPiece::set ( const char *  str)
inline

Definition at line 96 of file re2/re2/stringpiece.h.

◆ set() [2/4]

void re2::StringPiece::set ( const char *  str)
inline

Definition at line 96 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ set() [3/4]

void re2::StringPiece::set ( const char *  str,
size_type  len 
)
inline

Definition at line 101 of file re2/re2/stringpiece.h.

◆ set() [4/4]

void re2::StringPiece::set ( const char *  str,
size_type  len 
)
inline

Definition at line 101 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ size() [1/2]

size_type re2::StringPiece::size ( ) const
inline

Definition at line 80 of file re2/re2/stringpiece.h.

◆ size() [2/2]

size_type re2::StringPiece::size ( ) const
inline

Definition at line 80 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ starts_with() [1/2]

bool re2::StringPiece::starts_with ( const StringPiece x) const
inline

Definition at line 150 of file re2/re2/stringpiece.h.

◆ starts_with() [2/2]

bool re2::StringPiece::starts_with ( const StringPiece x) const
inline

Definition at line 150 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ substr() [1/2]

StringPiece re2::StringPiece::substr ( size_type  pos = 0,
size_type  n = npos 
) const

◆ substr() [2/2]

StringPiece re2::StringPiece::substr ( size_type  pos = 0,
size_type  n = npos 
) const

Definition at line 22 of file bloaty/third_party/re2/re2/stringpiece.cc.

◆ ToString() [1/2]

std::string re2::StringPiece::ToString ( ) const
inline

Definition at line 122 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ ToString() [2/2]

std::string re2::StringPiece::ToString ( ) const
inline

Definition at line 122 of file re2/re2/stringpiece.h.

Member Data Documentation

◆ const_iterator

const typedef char * re2::StringPiece::const_iterator

Definition at line 47 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ const_pointer

const typedef char * re2::StringPiece::const_pointer

Definition at line 44 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ const_reference

const typedef char & re2::StringPiece::const_reference

Definition at line 46 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ data_

const_pointer re2::StringPiece::data_
private

Definition at line 172 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ npos

static const size_type re2::StringPiece::npos = static_cast<size_type>(-1)
static

Definition at line 53 of file bloaty/third_party/re2/re2/stringpiece.h.

◆ size_

size_type re2::StringPiece::size_
private

Definition at line 173 of file bloaty/third_party/re2/re2/stringpiece.h.


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


grpc
Author(s):
autogenerated on Fri May 16 2025 03:03:43