acme
Foundational cross-platform layer of the ca2 framework
Loading...
Searching...
No Matches
str Class Reference

Public Types

enum  enum_pad { e_pad_left , e_pad_right }

Static Public Member Functions

static bool trimmed_is_empty (const ::scoped_string &scopedstr)
 #include "_____str_ch.h"
template<prototype_character CHAR_TYPE>
static string_base< const CHAR_TYPE * > repeat (const CHAR_TYPE *psz, character_count c)
static inline ::i32 compare_ignore_case (const string &left, const string &right, size_t len=0)
static bool equal_ignore_case (const string &left, const string &right, size_t len=0)
static void increment_digit_letter (string &str)
static void copy (string &str, const ::scoped_string &scopedstr, ::i32 iCount)
static string replace_with (const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstr, character_count iStart=0)
static string case_insensitive_replace_with (const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstr, character_count iStart=0)
::collection::count replace_with_ci_count (const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstr, character_count iStart=0)
::collection::count utf8_replace_with (string &str, const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstrOld, character_count iStart=0)
static string utf8_replace_with (const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstr, character_count iStart=0)
static string find_replace (const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstr, character_count iStart=0)
static string case_insensitive_find_replace (const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstr, character_count iStart=0)
static inline ::collection::count case_insensitive_find_replace_count (const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstr, character_count iStart=0)
static inline ::collection::count utf8_find_replace (string &str, const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstrNew, character_count iStart=0)
static string utf8_find_replace (const ::scoped_string &scopedstrOld, const ::scoped_string &scopedstrNew, const ::scoped_string &scopedstr, character_count iStart=0)
static string random_replace (::particle *pparticle, const string_array_base &straNew, const string_array_base &straOld, const ::scoped_string &scopedstr)
static character_count find_first (const string_array_base &straSearch, ::collection::index &iFound, const ::scoped_string &scopedstr, ::collection::index iStart=0)
static character_count case_insensitive_find (const ::scoped_string &scopedstrFind, const ::scoped_string &scopedstr, character_count iStart=0)
static character_count utf8_find (const ::scoped_string &scopedstrFind, const ::scoped_string &scopedstr, character_count iStart=0)
static character_count find_file_extension (const ::scoped_string &scopedstrExtension, const ::scoped_string &scopedstr, character_count iStart=0, character_count iLast=-1)
static character_count find_ww (const ::scoped_string &scopedstrFind, const ::scoped_string &scopedstr, character_count iStart=0)
static character_count find_wwci (const ::scoped_string &scopedstrFind, const ::scoped_string &scopedstr, character_count iStart=0)
static character_count find_aww (const ::scoped_string &scopedstrFind, const ::scoped_string &scopedstr, character_count iStart=0)
static character_count find_awwci (const ::scoped_string &scopedstrFind, const ::scoped_string &scopedstr, character_count iStart=0)
static string has_character (const ::scoped_string &scopedstrIfHasChar, const ::scoped_string &scopedstrBefore=nullptr, const ::scoped_string &scopedstrAfter=nullptr, const ::scoped_string &scopedstrDoesnt=nullptr)
static bool has_upper (const ::scoped_string &scopedstr)
static bool has_lower (const ::scoped_string &scopedstr)
static bool has_digit (const ::scoped_string &scopedstr)
static void calc_v1 (const ::scoped_string &scopedstr, bool &bHasUpper, bool &bHasLower, bool &bHasDigit)
static bool has_one_v1 (const ::scoped_string &scopedstr, bool &bHasUpper, bool &bHasLower, bool &bHasDigit)
static bool has_all_v1 (const ::scoped_string &scopedstr, bool &bHasUpper, bool &bHasLower, bool &bHasDigit)
static bool has_all_v1 (const ::scoped_string &scopedstr)
static string if_null (const ::scoped_string &scopedstr, const ::scoped_string &scopedstrIfNull=nullptr)
static string block (::ansi_character ch, ::i32 iSize)
static void fill (string &str, ::ansi_character ch)
static bool trim_any_quotes (string &str)
static bool paired_trim (string &str, ::ansi_character ch)
static bool trim (string &str)
static bool _008Trim (string &str)
static string & zero_pad (string &str, character_count iPad)
static string zero_padded (const ::scoped_string &scopedstr, character_count iPad)
::i32 get_escaped_char (const_char_pointer psz, character_count pos, character_count &retPos)
static bool get_curly_content (const_char_pointer psz, string &str)
static bool is_simple_natural (const_char_pointer psz, character_count iCount=-1)
static bool is_natural (const ::scoped_string &scopedstr)
static bool is_integer (const ::scoped_string &scopedstr)
static string ansi_lower (const ::scoped_string &scopedstr)
static string ansi_upper (const ::scoped_string &scopedstr)
static string get_word (const ::scoped_string &scopedstr, const ::scoped_string &scopedstrSeparator, bool bWithSeparator=false, bool bEndIsSeparator=true)
static string token (string &str, const ::scoped_string &scopedstrSeparatorText, bool bWithSeparator=false)
static string line (string &str, bool bWithNewLine=false)
static string pad (const ::scoped_string &scopedstr, ::collection::count iLen, const ::scoped_string &scopedstrPattern, enum_pad epad)
static character_count length (const_char_pointer pansichar)
static character_count length (const ::wd16_character *pwd16char)
static character_count length (const ::wd32_character *pwd32char)
template<typename TYPE>
static TYPE from_string (const_char_pointer psz)
static bool simple_escaped (const ::scoped_string &scopedstr, character_count pos)
static bool utf8_check_is_valid (const ::scoped_string &scopedstring)
static string q_valid (const ::scoped_string &scopedstr)
static inline ::ansi_character * dup (const_char_pointer psz)
static string signed_f64 (::f64 d)
static string signed_int (::i32 i)
static bool is_true (const ::scoped_string &scopedstr)
static character_count utf8_dec_len (const_char_pointer pszBeg, const_char_pointer psz)
static character_count utf8_inc_len (const_char_pointer psz)
static bool namespaced (const_char_pointer psz, const_char_pointer pszNamespace, const_char_pointer pszSeparator="::")
static void fix_eol (string &str)
static bool to (::i64 &i, const ::scoped_string &scopedstrParam)
static bool to (::i32 &i, const ::scoped_string &scopedstrParam)
static bool to (::u64 &u, const ::scoped_string &scopedstrParam)
static bool to (::u32 &u, const ::scoped_string &scopedstrParam)
static bool to (::i32 &i, ::i32 iBase, const ::scoped_string &scopedstrParam)
static bool to (::i64 &i, ::i32 iBase, const ::scoped_string &scopedstrParam)
static bool to (::u64 &u, ::i32 iBase, const ::scoped_string &scopedstrParam)
static bool to (::u32 &u, ::i32 iBase, const ::scoped_string &scopedstrParam)
static iptr to_iptr (const ::scoped_string &scopedstr)
::i32 to_int (const ::scoped_string &scopedstr)
::u32 to_u32 (const ::scoped_string &scopedstr)
::i64 to_i64 (const ::scoped_string &scopedstr)
::u64 to_u64 (const ::scoped_string &scopedstr)
static inline ::i32 to_with_fallback (const ::scoped_string &scopedstr, ::i32 iDefault)
static inline ::i64 to_with_fallback (const ::scoped_string &scopedstr, ::i64 iDefault)
static inline ::i32 to_with_fallback (const ::scoped_string &scopedstr, ::i32 iDefault, ::i32 iBase)
static inline ::i64 to_with_fallback (const ::scoped_string &scopedstr, ::i64 iDefault, ::i32 iBase)
static bool begins_ci_iws (const ::scoped_string &scopedstr, const ::scoped_string &scopedstrPrefix)
static bool begins_ci_iws (const wstring &wstr, const wstring &wstrPrefix)
static character_count unichar_count (const_char_pointer pstr)
static character_count unichar_count (const ::wd16_character *pstr)
static character_count unichar_count (const ::wd32_character *pstr)
static void get_lines (::string &str, bool bFinal, const ::function< void(const ::scoped_string &, bool bCarriage) > &functionNewLine)
static void get_lines (::string_array_base &stra, ::string &str, const ::scoped_string &scopedstrPrefix, bool bFinal, ::particle *pparticleSynchronization=nullptr, ::file::file *pfileLines=nullptr)
static character_count x_find_index (const ::scoped_string &scopedstr, const ::scoped_string &scopedstrSearchedTerm)
static bool x_contains (const ::scoped_string &scopedstr, const ::scoped_string &scopedstrSearchedTerm)
static bool x_contains (const ::scoped_string &scopedstr, const ::string_array_base &straSearchedTerm)

Member Function Documentation

◆ q_valid()

string str::q_valid ( const ::scoped_string & scopedstr)
static

q(between quotes :-) )-valid string

◆ utf8_check_is_valid()

bool str::utf8_check_is_valid ( const ::scoped_string & scopedstr)
static

q(between quotes :-) )-valid string from:http://www.zedwood.com/article/cpp-is-valid-utf8-string-function more invalid strings to test: http://stackoverflow.com/questions/1301402/example-invalid-utf8-string


The documentation for this class was generated from the following files:
  • prototype/string/_str.h
  • prototype/string/_str.cpp
  • prototype/string/_str_impl.cpp
  • prototype/string/_str_impl.h
  • prototype/string/str_to.cpp