65 : items_(other.items_)
97 return (items_ + size_);
117 return items_[index];
124 return items_[index];
126 throw std::invalid_argument(
"index");
132 items_ = other.items_;
141 std::swap(items_, other.items_);
143 std::swap(size_, other.size_);
157 return StrRef(str.data(), str.size());
163 return StrRef(cStr, cStr ? strlen(cStr) : 0);
169 return std::string(ref.
items(), ref.
size());
181 return std::string(1, character);
187 str.append(1, character);
191inline void toStr(std::string& str,
const std::string& value)
205 return !(left == right);
261 return (0 != result ? (0 > result) : (left.
size() < right.
size()));
267 return (right < left);
#define ONIXS_CMEMDH_NAMESPACE_BEGIN
#define ONIXS_CMEMDH_LTWT
#define ONIXS_CMEMDH_NAMESPACE_END
#define ONIXS_CMEMDH_NULLPTR
Provides efficient way of accessing text-based values without copying content of the text being refer...
const Char * items() const
Read-only content.
Iterator begin() const
STL-like begin().
StrRef(const Char *chars, size_t size)
Explicit reference initialization.
size_t size() const
Number of chars.
void reset(const Char *chars, size_t size)
Updates the given instance to refer to the new text.
Iterator end() const
STL-like end().
bool empty() const
Indicates whether the referenced text is empty.
const Char * Iterator
STL-like iterator.
void swap(StrRef &other)
Swaps content with the other instance.
StrRef()
Initializes the instance referring to nothing.
void reset()
Resets the reference to nothing.
const Char & operator[](size_t index) const
Provides per-item access.
StrRef & operator=(const StrRef &other)
Reinitializes from the other instance.
StrRef(const StrRef &other)
Initializes as the clone of other instance.
const Char & at(size_t index) const
Provides bound-checked per-item access.
bool operator>(const FixedPointDecimal< Mantissa, Exponent > &left, const FixedPointDecimal< Mantissa, Exponent > &right)
Compares two fixed-point decimals.
bool operator!=(const FixedPointDecimal< Mantissa, Exponent > &left, const FixedPointDecimal< Mantissa, Exponent > &right)
Compares two fixed-point decimals.
char Char
Character type alias.
bool operator==(const FixedPointDecimal< Mantissa, Exponent > &left, const FixedPointDecimal< Mantissa, Exponent > &right)
Compares two fixed-point decimals.
void toStr(std::string &, BookState::Enum)
Serializes book state value into a string.
StrRef toStrRef(const std::string &str)
Constructs StrRef instance over std::string content.
bool operator<(const FixedPointDecimal< Mantissa, Exponent > &left, const FixedPointDecimal< Mantissa, Exponent > &right)
Compares two fixed-point decimals.
std::ostream & operator<<(std::ostream &stream, const IssueArgs &args)