… | |
… | |
84 | } |
84 | } |
85 | |
85 | |
86 | // returns true if the substring is contained in the shstr |
86 | // returns true if the substring is contained in the shstr |
87 | // if the shstr is 0, then this always returns false. |
87 | // if the shstr is 0, then this always returns false. |
88 | // the shstr is (theoretically) treated as a comma/colon/space etc. separated list. |
88 | // the shstr is (theoretically) treated as a comma/colon/space etc. separated list. |
89 | bool contains (const char *substring) const |
89 | bool contains (const char *substring) const; |
90 | { |
|
|
91 | return s != null () && strstr (s, substring); |
|
|
92 | } |
|
|
93 | |
90 | |
94 | //TODO: case sensitive should be eradicated |
91 | //TODO: case sensitive should be eradicated |
95 | bool eq_nc (const char *otherstring) const |
92 | bool eq_nc (const char *otherstring) const |
96 | { |
93 | { |
97 | return !strcasecmp (s, otherstring); |
94 | return !strcasecmp (s, otherstring); |