/* $DOC$ $AUTHOR$ 2016 Pete D. $TEMPLATE$ Function $NAME$ hb_ATokens() $CATEGORY$ API $SUBCATEGORY$ Strings $ONELINER$ Parses a complex string (e.g. a sentence or multi-line text) into individual tokens (words or other string chunks depending on delimiter used). $SYNTAX$ hb_ATokens( , [|], [], ; [] ) --> aTokens $ARGUMENTS$ Complex string to be parsed. | flag defined instead of , then end of line marker(s) will be used as delimiter. Boolean flag indicating if quoted substrings will be tokenized or not. Boolean flag indicating that only double-quoted substrings will be tokenized. $RETURNS$ A character array, filled with the individual tokens found. $DESCRIPTION$ This function analyses the complex string and splits it into separate sub-strings (tokens) that are delimited by or by space character, if no delimiter is passed, or by EOL marker if instead of is specified. The located tokens, are stored in an array which is returned by the function. If is .T. (default: .F.), the quoted sub-strings (if any) within are not tokenized. If is .T. only the double quote `"` is recognized as a quote sign. This argument is meaningful only when is .T. $NOTES$ 1) the tokenization process is case sensitive, in the (rare) case where is an alphabetic character. 2) The delimiters are removed (trimmed) from tokens. $EXAMPLES$ LOCAL cString := "Harbour is proven to be stable, robust and efficient." LOCAL aTokens := hb_ATokens( cString ) AEval( aTokens, {| token, n | QOut( hb_ntos(n), token ) } ) ? aTokens := hb_ATokens( cString, "," ) AEval( aTokens, {| token, n | QOut( hb_ntos(n), token ) } ) $STATUS$ R $COMPLIANCE$ H $PLATFORMS$ All $FILES$ Library is core $SEEALSO$ SubStr() $END$ */