Changeset 7707 for trunk/psLib/src/sys/psString.h
- Timestamp:
- Jun 27, 2006, 10:33:22 AM (20 years ago)
- File:
-
- 1 edited
-
trunk/psLib/src/sys/psString.h (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psLib/src/sys/psString.h
r7653 r7707 14 14 * @author David Robbins, MHPCC 15 15 * 16 * @version $Revision: 1.2 3$ $Name: not supported by cvs2svn $17 * @date $Date: 2006-06-2 3 20:29:39$16 * @version $Revision: 1.24 $ $Name: not supported by cvs2svn $ 17 * @date $Date: 2006-06-27 20:33:22 $ 18 18 * 19 19 * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii … … 103 103 */ 104 104 psList *psStringSplit( 105 const char *string, 106 const char *splitters, 107 bool multipleAreSignificant 105 const char *string, ///< String to split 106 const char *splitters, ///< Characters on which to split 107 bool multipleAreSignificant ///< Are multiple occurences significant? 108 108 ); 109 109 110 // Same as psStringSplit, but return result as an array 111 psArray *psStringSplitArray(const char *string, // String to split 112 const char *splitters, // Characters on which to split 113 bool multipleAreSignificant // Are multiple occurences significant? 114 ); 110 /** Procedure to split the input string into a psArray of psStrings. 111 * 112 * The string is split at any one of the characters in splitters. Split 113 * strings of zero length should not be included in the output list. 114 * 115 * @return psArray*: The array of (split) psStrings. 116 */ 117 psArray *psStringSplitArray( 118 const char *string, ///< String to split 119 const char *splitters, ///< Characters on which to split 120 bool multipleAreSignificant ///< Are multiple occurences significant? 121 ); 115 122 116 123 // Given the input string, search for all copies of the key, and replace with the replacement value 117 124 // the input string may be freed if not needed 118 char *psStringSubstitute (char *input, ///< input string to be modified 119 const char *replace, ///< replacement value 120 const char *key ///< string to be replaced in input 121 ); 125 /** Procedure to search an input string and substitute strings where desired. 126 * 127 * The input string is searched for all instances of the key, which is then replaced with 128 * the replacement value wherever found. The input string may be freed if not needed. 129 * 130 * @return char*: the modified input string. 131 */ 132 char *psStringSubstitute ( 133 char *input, ///< input string to be modified 134 const char *replace, ///< replacement value 135 const char *key ///< string to be replaced in input 136 ); 122 137 123 138 // strip whitespace from head and tail of string 124 size_t psStringStrip(char *string); 139 /** Procedure to strip the whitespace from the head and tail of a string. 140 * 141 * @return size_t: Number of whitespaces removed. 142 */ 143 size_t psStringStrip( 144 char *string ///< input string to be stripped. 145 ); 125 146 126 147
Note:
See TracChangeset
for help on using the changeset viewer.
