69 template <
size_t Size>
86 : items_(other.items_)
123 return (items_ + size_);
148 return items_[index];
156 return items_[index];
158 throw std::invalid_argument(
"index");
167 items_ = other.items_;
179 std::swap(items_, other.items_);
180 std::swap(size_, other.size_);
188 size_t length =
size();
190 while(length > 0 && isspace(
operator[](length - 1)))
208 const std::string& str)
210 return StrRef(str.data(), str.size());
234 return std::string(ref.
items(), ref.
size());
253 return std::string(1, character);
263 str.append(1, character);
271 const std::string& value)
297 return !(left == right);
305 const std::string& str)
315 const std::string& str)
324 const std::string& str,
334 const std::string& str,
396 if (0 == compareResult)
399 static_cast<ptrdiff_t
>(
403 return (0 > compareResult);
413 return (right < left);
420 std::ostream& stream,
#define ONIXS_HKEX_OMDC_CONSTEXPR
#define ONIXS_HKEX_OMDC_NOTHROW
#define ONIXS_HKEX_OMDC_NULLPTR
Provides efficient way of accessing text-based FIX field values.
void reset(const Char *chars, size_t size) noexcept
Updates data being referenced.
void reset() noexcept
Resets reference to nothing.
void swap(StrRef &other) noexcept
Swaps content with other instance.
StrRef() noexcept
Initializes blank instance.
size_t size() const noexcept
Number of chars.
bool empty() const noexcept
Indicates whether array of zero length.
const Char * Iterator
STL-like iterator.
StrRef & operator=(const StrRef &other) noexcept
Reinitializes from another instance.
StrRef(const Char *chars, size_t size) noexcept
Full initialization.
Iterator end() const noexcept
STL-like end().
const Char * items() const noexcept
Read-only content.
StrRef trim() const noexcept
constexpr StrRef(const char(&value)[Size]) noexcept
StrRef(const StrRef &other) noexcept
Initializes as clone of other instance.
Iterator begin() const noexcept
STL-like begin().
const Char & operator[](size_t index) const
const Char & at(size_t index) const
bool operator>(const StrRef &left, const StrRef &right)
Establishes order over string refs.
bool operator<(const StrRef &left, const StrRef &right)
Establishes order over string refs.
ONIXS_HKEX_OMDC_API void toStr(std::string &, Side::Enum)
Appends string presentation of object.
char Char
Character type alias.
ONIXS_HKEX_OMDC_API std::ostream & operator<<(std::ostream &stream, const ServiceDescriptor &descriptor)
StrRef toStrRef(const std::string &str)
Constructs StrRef instance over std::string content.
bool operator==(const PriceLevel &l, const PriceLevel &r) noexcept
compare
bool operator!=(const StrRef &left, const StrRef &right)
Compares with another instance.