ucx/string.h

changeset 149
3bf87676d42d
parent 148
c27c2425c0b1
child 160
302dddaf741d
     1.1 --- a/ucx/string.h	Mon Aug 19 10:44:11 2013 +0200
     1.2 +++ b/ucx/string.h	Mon Aug 19 11:54:54 2013 +0200
     1.3 @@ -301,6 +301,22 @@
     1.4  int sstrcmp(sstr_t s1, sstr_t s2);
     1.5  
     1.6  /**
     1.7 + * Compares two UCX strings ignoring the case.
     1.8 + * 
     1.9 + * At first it compares the sstr_t.length attribute of the two strings. If and
    1.10 + * only if the lengths match, both strings are compared char by char ignoring
    1.11 + * the case.
    1.12 + * 
    1.13 + * @param s1 the first string
    1.14 + * @param s2 the second string
    1.15 + * @return -1, if the length of s1 is less than the length of s2 or 1, if the 
    1.16 + * length of s1 is greater than the length of s2 or the difference between the
    1.17 + * first two differing characters otherwise (i.e. 0 if the strings match and
    1.18 + * no characters differ)
    1.19 + */
    1.20 +int sstrcasecmp(sstr_t s1, sstr_t s2);
    1.21 +
    1.22 +/**
    1.23   * Creates a duplicate of the specified string.
    1.24   * 
    1.25   * The new sstr_t will contain a copy allocated by standard

mercurial