(c = symbols_; *c; c++) {
52 if(!
isalpha(*c))
return false;
63 for(c = symbols_; *c; c++) {
64 if(
isspace(*c))
return false;
73 for(string::const_iterator c = symbols_.begin (); c != symbols_.end (); c++) {
74 if(!
isspace(*c))
return false;
83 for(c = symbols_; *c; c++) {
84 if(!
islower(*c))
return false;
94 for(c = symbols_; *c; c++) {
95 if(!
isupper(*c))
return false;
104 for(
char*
i= symbols_; *
i;
i++) *
i=
tolower(*
i);
109 for(
char*
i= symbols_; *
i;
i++) *
i=
toupper(*
i);
114 boolupperEqualsLower_)
116 stringsymbols (symbols_);
117 if(upperEqualsLower_) {
118 for(string::iterator
i= symbols.begin ();
i!= symbols.end ();
i++) {
122sort <string::iterator> (symbols.begin (), symbols.end ());
123 returnunique <string::iterator> (symbols.begin (), symbols.end ()) != symbols.end ();
135 if(
i== symbols_)
return;
137 for(j = symbols_; *
i;
i++, j++)
147 char*
str=
new char[symbols_.size () + 1];
149strcpy (
str, symbols_.c_str ());
159reverse (symbols_, symbols_ + strlen (symbols_));
161reverse (symbols_, symbols_ + strlen (symbols_));
166 char*
str=
new char[symbols_.size () + 1];
168strcpy (
str, symbols_.c_str ());
181 for(
i= j = symbols_; *
i;
i++) {
182 if(!
isspace(*
i) || (*
i!=
' '&& eraseBlankOnly_)) {
192 char*
str=
new char[symbols_.size () + 1];
194strcpy (
str, symbols_.c_str ());
207 for(
i= symbols_; *
i;
i++)
211 for(s = c_; *s; s++)
223 if(
i== symbols_)
return;
225 for(j = symbols_; *
i;
i++, j++)
235 char*
str=
new char[symbols_.size () + 1];
237strcpy (
str, symbols_.c_str ());
246reverse (symbols_, symbols_ + strlen (symbols_));
248reverse (symbols_, symbols_ + strlen (symbols_));
253 char*
str=
new char[symbols_.size () + 1];
255strcpy (
str, symbols_.c_str ());
268 for(
i= j = symbols_; *
i;
i++)
272 for(s = c_; *s; s++)
292 char*
str=
new char[symbols_.size () + 1];
294strcpy (
str, symbols_.c_str ());
305 for(
i= symbols_; *
i;
i++)
307 if(*
i== cIn_) *
i= cOut_;
313 char*
str=
new char[symbols_.size () + 1];
315strcpy (
str, symbols_.c_str ());
326 if(! symbols_ || ! *symbols_)
return;
327 if(symbols_ [strlen (symbols_) - 1] ==
'\r') symbols_ [strlen (symbols_) - 1] =
'\0';
334 if(symbols_.empty ())
return;
335 if(*symbols_.rbegin () ==
'\r') symbols_.erase (symbols_.size () - 1);
340 assert(strlen (symbols_) != 0);
355symbols_ [0] =
'\0';
366strcpy (symbols_,
str.c_str ());
371 char*
str=
new char[symbols_.size () + 1];
373strcpy (
str, symbols_.c_str ());
381std::vector <std::string> *strVec_,
386 assert(split_.length () != 0);
391string::size_type pos0 = 0;
393 for(string::size_type pos =
str.find (split_ [0]); pos != string::npos && pos !=
str.length (); )
395 if(
str.substr (pos,
min(split_.length (),
str.length () - pos)) != split_) {
401strVec_->push_back (pos == pos0 ?
string(
"") :
str.substr (pos0, pos - pos0));
402pos += split_.length ();
406strVec_->push_back (
str.length () == pos0 ?
string(
"") :
str.substr (pos0,
str.length () - pos0));
413std::vector <std::string> strVec;
415 split(&strVec, str_, split_);
417 returnstrVec.size ();
static const char * str(char *buf, int n)
void toUpper(char *symbols_)
bool isAllWhiteSpace(const std::string &symbols_)
bool isNoWhiteSpace(const char *symbols_)
void eraseFinalWhiteSpace(char *symbols_)
void eraseCarriageReturn(char *symbols_)
void eraseFinalChar(char *symbols_, const char *c_)
size_t splitCount(const std::string &str_, const std::string &split_)
void eraseInitialWhiteSpace(char *symbols_)
void split(std::vector< std::string > *strVec, const std::string &str_, const std::string &split_)
bool isAlpha(const char *symbols_)
void eraseInitialChar(char *symbols_, const char *c_)
bool isUpper(const char *symbols_)
void substituteChar(char *symbols_, const char cOut_, const char cIn_)
void whiteSpace2UnderScore(char *symbols_)
void eraseWhiteSpace(char *symbols_, bool eraseBlankOnly_=false)
void toLower(char *symbols_)
bool isLower(const char *symbols_)
void eraseChar(char *symbols_, const char *c_)
bool isReplicate(const std::string &symbols_, bool upperEqualsLower_=false)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4