26 #if ! defined (octave_oct_string_h)
27 #define octave_oct_string_h 1
29 #include "octave-config.h"
60 bool strcmp (
const T& str_a,
const T& str_b);
73 bool strcmp (
const T& str_a,
const typename T::value_type *str_b);
84 bool strcmpi (
const T& str_a,
const T& str_b);
94 bool strcmpi (
const T& str_a,
const typename T::value_type *str_b);
104 template <
typename T>
105 bool strncmp (
const T& str_a,
const T& str_b,
106 const typename T::size_type
n);
109 template <
typename T>
110 bool strncmp (
const T& str_a,
const typename T::value_type *str_b,
111 const typename T::size_type
n);
121 template <
typename T>
122 bool strncmpi (
const T& str_a,
const T& str_b,
123 const typename T::size_type
n);
126 template <
typename T>
127 bool strncmpi (
const T& str_a,
const typename T::value_type *str_b,
128 const typename T::size_type
n);
133 extern OCTAVE_API std::string
134 u8_to_encoding (
const std::string& who,
const std::string& u8_string,
135 const std::string& encoding);
137 extern OCTAVE_API std::string
139 const std::string& encoding);
147 extern OCTAVE_API
unsigned int
148 u8_validate (
const std::string& who, std::string& in_string,
153 template <
typename T>
154 extern OCTAVE_API std::string
bool strncmp(const T &str_a, const T &str_b, const typename T::size_type n)
True if the first N characters are the same.
bool strncmpi(const T &str_a, const T &str_b, const typename T::size_type n)
True if the first N characters are the same, ignoring case.
OCTAVE_API std::string u8_to_encoding(const std::string &who, const std::string &u8_string, const std::string &encoding)
bool strcmp(const T &str_a, const T &str_b)
True if strings are the same.
bool strcmpi(const T &str_a, const T &str_b)
True if strings are the same, ignoring case.
OCTAVE_API std::string u8_from_encoding(const std::string &who, const std::string &native_string, const std::string &encoding)
OCTAVE_API Complex str2double(const std::string &str_arg)
OCTAVE_API unsigned int u8_validate(const std::string &who, std::string &in_string, const u8_fallback_type type=U8_REPLACEMENT_CHAR)
std::complex< double > Complex
OCTAVE_API std::string rational_approx(T val, int len)