Lines Matching refs:StringPiece
26 class StringPiece {
28 StringPiece() : mData(nullptr), mLength(0) {} in StringPiece() function
29 StringPiece(const char* data) : mData(data), mLength(data == nullptr ? 0 : strlen(data)) {} in StringPiece() function
30 StringPiece(const char* data, size_t length) : mData(data), mLength(length) {} in StringPiece() function
31 StringPiece(const std::string& str) : mData(str.data()), mLength(str.size()) {} in StringPiece() function
32 StringPiece(std::string_view str) : mData(str.data()), mLength(str.size()) {} in StringPiece() function
41 inline StringPiece substr(size_t from, size_t length) const { in substr()
42 return StringPiece(mData + from, length); in substr()
60 inline bool operator==(const StringPiece& l, const StringPiece& r) {
73 inline bool operator==(const StringPiece& l, const char* s) {
81 inline bool operator!=(const StringPiece& l, const StringPiece& r) {
85 inline bool operator!=(const StringPiece& l, const char* s) {
91 SplitIterator(const StringPiece& string, char delimiter) in SplitIterator()
94 inline StringPiece next() { in next()
96 return StringPiece(); in next()
108 StringPiece mString;