Q_ENTRY* qStrTokenizer ( char *  str,
const char *  delimiters 
)

String Tokenizer

Parameters:
str source string
delimiters string that specifies a set of delimiters that may surround the token being extracted
Returns:
a pointer to the Q_ENTRY list
Note:
Tokens will be stored at Q_ENTRY list with key 1, 2, 3, 4, 5...
   FILE *fp = fopen("/etc/passwd", "r");
   char *buf;
   while((buf = qFileReadLine(fp)) != NULL) {
     qStrTrimTail(buf);
      Q_ENTRY *tokens = qStrTokenizer(buf, ":");
      printf("%s\n", qEntryGetStr(tokens, "1"));
      qEntryFree(tokens);
   }
   fclose(fp);

Definition at line 412 of file qString.c.


Generated on Mon Mar 26 07:00:51 2018 for JSOC_Documentation by  doxygen 1.5.7.1