#include "oct-string.h"
#include <algorithm>
#include <cctype>
#include <cstring>
#include <iomanip>
#include <string>
#include "Array.h"
#include "lo-ieee.h"
#include "lo-mappers.h"
#include "uniconv-wrappers.h"
#include "unistr-wrappers.h"
#include "unwind-prot.h"
Go to the source code of this file.
Macros | |
#define | INSTANTIATE_OCTAVE_STRING(T, API) |
Typedefs | |
typedef octave::string::codecvt_u8::ExternT | ExternT |
typedef octave::string::codecvt_u8::InternT | InternT |
typedef octave::string::codecvt_u8::StateT | StateT |
Functions | |
static std::istringstream & | extract_num (std::istringstream &is, double &num, bool &imag, bool &have_sign) |
static bool | is_imag_unit (int c) |
template<> | |
octave_idx_type | numel (const Array< char > &str) |
template<typename T > | |
T::size_type | numel (const T &str) |
template OCTAVE_API bool | octave::string::strcmp< std::string > (const std::string &, const std::string &) |
template OCTAVE_API bool | octave::string::strcmp< std::string > (const std::string &, const typename std::string ::value_type *) |
template OCTAVE_API bool | octave::string::strcmpi< std::string > (const std::string &, const std::string &) |
template OCTAVE_API bool | octave::string::strcmpi< std::string > (const std::string &, const typename std::string ::value_type *) |
template OCTAVE_API bool | octave::string::strncmp< std::string > (const std::string &, const std::string &, const typename std::string ::size_type) |
template OCTAVE_API bool | octave::string::strncmp< std::string > (const std::string &, const typename std::string ::value_type *, const typename std::string ::size_type) |
template OCTAVE_API bool | octave::string::strncmpi< std::string > (const std::string &, const std::string &, const typename std::string ::size_type n) |
template OCTAVE_API bool | octave::string::strncmpi< std::string > (const std::string &, const typename std::string ::value_type *, const typename std::string ::size_type) |
template<typename T > | |
std::string | rational_approx (T val, int len) |
template OCTAVE_API std::string | rational_approx< double > (double val, int len) |
template OCTAVE_API std::string | rational_approx< float > (float val, int len) |
static void | set_component (Complex &c, double num, bool imag) |
static double | single_num (std::istringstream &is) |
template<> | |
bool | sizes_cmp (const Array< char > &str_a, const Array< char > &str_b) |
template<> | |
bool | sizes_cmp (const Array< char > &str_a, const char *str_b) |
template<typename T > | |
bool | sizes_cmp (const T &str_a, const T &str_b) |
template<typename T > | |
bool | sizes_cmp (const T &str_a, const typename T::value_type *str_b) |
template<typename T > | |
static bool | str_data_cmp (const typename T::value_type *a, const typename T::value_type *b, const typename T::size_type n) |
template<typename T > | |
static bool | str_data_cmpi (const typename T::value_type *a, const typename T::value_type *b, const typename T::size_type n) |
template<typename T > | |
T::size_type | strlen (const typename T::value_type *str) |
#define INSTANTIATE_OCTAVE_STRING | ( | T, | |
API | |||
) |
Definition at line 213 of file oct-string.cc.
typedef octave::string::codecvt_u8::ExternT ExternT |
Definition at line 611 of file oct-string.cc.
typedef octave::string::codecvt_u8::InternT InternT |
Definition at line 610 of file oct-string.cc.
typedef octave::string::codecvt_u8::StateT StateT |
Definition at line 612 of file oct-string.cc.
|
static |
Definition at line 301 of file oct-string.cc.
References imag(), is_imag_unit(), and single_num().
|
inlinestatic |
Definition at line 241 of file oct-string.cc.
Referenced by extract_num().
octave_idx_type numel | ( | const Array< char > & | str | ) |
Definition at line 78 of file oct-string.cc.
References Array< T, Alloc >::numel().
T::size_type numel | ( | const T & | str | ) |
Definition at line 71 of file oct-string.cc.
Referenced by ov_range< T >::ov_range(), intNDArray< T >::abs(), all_scalar_1x1(), intNDArray< T >::any_element_not_one_or_zero(), range< T, typename std::enable_if< std::is_floating_point< T >::value >::type >::array_value(), Array< T, Alloc >::as_column(), dim_vector::as_column(), octave_uint64_matrix::as_mxArray(), ov_range< T >::as_mxArray(), Array< T, Alloc >::as_row(), dim_vector::as_row(), Array< T, Alloc >::assign(), Sparse< T, Alloc >::assign(), octave_uint64_matrix::bool_array_value(), octave_lazy_index::byte_size(), Array< T, Alloc >::byte_size(), octave_bool_matrix::char_array_value(), octave_uint64_matrix::char_array_value(), ov_range< T >::char_array_value(), Sparse< T, Alloc >::checkelem(), range< T, typename std::enable_if< std::is_floating_point< T >::value >::type >::cols(), Range::cols(), range< T, typename std::enable_if< std::is_floating_point< T >::value >::type >::columns(), Range::columns(), ov_range< T >::complex_value(), textscan_format_list::current(), Array< T, Alloc >::delete_elements(), Sparse< T, Alloc >::delete_elements(), Array< T, Alloc >::diag(), ov_range< T >::dims(), ov_range< T >::do_index_op(), do_simple_cellfun(), ov_range< T >::double_value(), string_vector::empty(), ov_range< T >::fast_elem_extract(), Fbitshift(), Fgmtime(), Array< T, Alloc >::fill(), fill_matrix(), Array< T, Alloc >::find(), ov_range< T >::float_complex_value(), octave_base_diag< DMT, MT >::float_value(), ov_range< T >::float_value(), Flocaltime(), Fquit(), MArray< T >::idx_add(), MArray< double >::idx_max(), MArray< T >::idx_max(), img_float2uint(), ind2sub(), Array< T, Alloc >::index(), Sparse< T, Alloc >::index(), octave_base_diag< DMT, MT >::is_true(), ov_range< T >::is_true(), Array< T, Alloc >::isempty(), DiagArray2< T >::isempty(), PermMatrix::isempty(), range< T, typename std::enable_if< std::is_floating_point< T >::value >::type >::isempty(), Range::isempty(), Array< T, Alloc >::issorted(), octave_map::length(), Array< T, Alloc >::lookup(), range< T, typename std::enable_if< std::is_floating_point< T >::value >::type >::make_n_element_range(), Array< T, Alloc >::map(), string_vector::max_length(), textscan_format_list::next(), octave_lazy_index::nnz(), Array< T, Alloc >::nnz(), Array< T, Alloc >::nth_element(), intNDArray< T >::operator!(), ov_range< T >::print_name_tag(), Array< T, Alloc >::resize1(), ov_range< T >::short_disp(), intNDArray< T >::signum(), Array< T, Alloc >::test(), ov_range< T >::try_narrowing_conversion(), and set_path_model::update_data().
template OCTAVE_API bool octave::string::strcmp< std::string > | ( | const std::string & | , |
const std::string & | |||
) |
template OCTAVE_API bool octave::string::strcmp< std::string > | ( | const std::string & | , |
const typename std::string ::value_type * | |||
) |
template OCTAVE_API bool octave::string::strcmpi< std::string > | ( | const std::string & | , |
const std::string & | |||
) |
template OCTAVE_API bool octave::string::strcmpi< std::string > | ( | const std::string & | , |
const typename std::string ::value_type * | |||
) |
template OCTAVE_API bool octave::string::strncmp< std::string > | ( | const std::string & | , |
const std::string & | , | ||
const typename std::string ::size_type | |||
) |
template OCTAVE_API bool octave::string::strncmp< std::string > | ( | const std::string & | , |
const typename std::string ::value_type * | , | ||
const typename std::string ::size_type | |||
) |
template OCTAVE_API bool octave::string::strncmpi< std::string > | ( | const std::string & | , |
const std::string & | , | ||
const typename std::string ::size_type | n | ||
) |
template OCTAVE_API bool octave::string::strncmpi< std::string > | ( | const std::string & | , |
const typename std::string ::value_type * | , | ||
const typename std::string ::size_type | |||
) |
std::string rational_approx | ( | T | val, |
int | len | ||
) |
template OCTAVE_API std::string rational_approx< double > | ( | double | val, |
int | len | ||
) |
template OCTAVE_API std::string rational_approx< float > | ( | float | val, |
int | len | ||
) |
|
inlinestatic |
Definition at line 441 of file oct-string.cc.
References imag().
|
static |
Definition at line 245 of file oct-string.cc.
References Inf, NaN, and octave_NA.
Referenced by extract_num().
Definition at line 99 of file oct-string.cc.
References Array< T, Alloc >::dims().
bool sizes_cmp | ( | const Array< char > & | str_a, |
const char * | str_b | ||
) |
Definition at line 113 of file oct-string.cc.
References Array< T, Alloc >::isvector(), Array< T, Alloc >::numel(), Array< T, Alloc >::rows(), and strlen().
bool sizes_cmp | ( | const T & | str_a, |
const T & | str_b | ||
) |
Definition at line 92 of file oct-string.cc.
bool sizes_cmp | ( | const T & | str_a, |
const typename T::value_type * | str_b | ||
) |
Definition at line 106 of file oct-string.cc.
|
static |
Definition at line 47 of file oct-string.cc.
References n.
|
static |
Definition at line 58 of file oct-string.cc.
References n.
T::size_type strlen | ( | const typename T::value_type * | str | ) |
Definition at line 85 of file oct-string.cc.
Referenced by charNDArray::charNDArray(), mxArray_base_full::mxArray_base_full(), KeyboardTranslatorManager::defaultTranslator(), extract_keyword(), F77_FUNC(), fgets(), TerminalView::fontChange(), handle_message(), charMatrix::insert(), max_str_len(), mexErrMsgIdAndTxt(), mexErrMsgTxt(), mexWarnMsgIdAndTxt(), mexWarnMsgTxt(), octave__scan_string(), octave_getcwd_wrapper(), octave_tex__scan_string(), gzfilebuf::open_mode(), Vt102Emulation::sendString(), mxArray_matlab::set_class_name(), sizes_cmp(), strsave(), mxArray::strsave(), u8_to_wchar(), KeyboardTranslator::Entry::unescape(), and error_system::vwarning().