Changeset 1bfd3d3 in mainline for uspace/lib/c/generic/adt
- Timestamp:
- 2010-11-19T22:02:09Z (15 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 973ef9fc, a9c6b966
- Parents:
- cc3c2a1c
- Location:
- uspace/lib/c/generic/adt
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/adt/char_map.c
rcc3c2a1c r1bfd3d3 60 60 * @param[in] value The integral value to be stored for the key character 61 61 * string. 62 * @return sEOK on success.63 * @return sENOMEM if there is not enough memory left.64 * @return sEEXIST if the key character string is already used.62 * @return EOK on success. 63 * @return ENOMEM if there is not enough memory left. 64 * @return EEXIST if the key character string is already used. 65 65 */ 66 66 static int … … 107 107 * 108 108 * @param[in] map The character string to integer map. 109 * @return sTRUE if the map is valid.110 * @return sFALSE otherwise.109 * @return TRUE if the map is valid. 110 * @return FALSE otherwise. 111 111 */ 112 112 static int char_map_is_valid(const char_map_t *map) … … 127 127 * @param[in] value The integral value to be stored for the key character 128 128 * string. 129 * @return sEOK on success.130 * @return sEINVAL if the map is not valid.131 * @return sEINVAL if the identifier parameter is NULL.132 * @return sEINVAL if the length parameter zero (0) and the129 * @return EOK on success. 130 * @return EINVAL if the map is not valid. 131 * @return EINVAL if the identifier parameter is NULL. 132 * @return EINVAL if the length parameter zero (0) and the 133 133 * identifier parameter is an empty character string (the 134 134 * first character is the terminating zero ('\0') 135 135 * character. 136 * @return sEEXIST if the key character string is already used.137 * @return sOther error codes as defined for the136 * @return EEXIST if the key character string is already used. 137 * @return Other error codes as defined for the 138 138 * char_map_add_item() function. 139 139 */ … … 196 196 * zero (0) which means that the string is processed until 197 197 * the terminating zero ('\0') character is found. 198 * @return sThe node holding the integral value assigned to the key198 * @return The node holding the integral value assigned to the key 199 199 * character string. 200 * @return sNULL if the key is not assigned a node.200 * @return NULL if the key is not assigned a node. 201 201 */ 202 202 static char_map_t * … … 239 239 * zero (0) which means that the string is processed until 240 240 * the terminating zero ('\0') character is found. 241 * @return sThe integral value assigned to the key character string.242 * @return sCHAR_MAP_NULL if the key is not assigned a value.241 * @return The integral value assigned to the key character string. 242 * @return CHAR_MAP_NULL if the key is not assigned a value. 243 243 */ 244 244 int char_map_exclude(char_map_t *map, const char *identifier, size_t length) … … 267 267 * zero (0) which means that the string is processed until 268 268 * the terminating zero ('\0') character is found. 269 * @return sThe integral value assigned to the key character string.270 * @return sCHAR_MAP_NULL if the key is not assigned a value.269 * @return The integral value assigned to the key character string. 270 * @return CHAR_MAP_NULL if the key is not assigned a value. 271 271 */ 272 272 int char_map_find(const char_map_t *map, const char *identifier, size_t length) … … 281 281 * 282 282 * @param[in,out] map The character string to integer map. 283 * @return sEOK on success.284 * @return sEINVAL if the map parameter is NULL.285 * @return sENOMEM if there is not enough memory left.283 * @return EOK on success. 284 * @return EINVAL if the map parameter is NULL. 285 * @return ENOMEM if there is not enough memory left. 286 286 */ 287 287 int char_map_initialize(char_map_t *map) … … 319 319 * @param[in] value The integral value to be stored for the key character 320 320 * string. 321 * @return sEOK on success.322 * @return sEINVAL if the map is not valid.323 * @return sEINVAL if the identifier parameter is NULL.324 * @return sEINVAL if the length parameter zero (0) and the321 * @return EOK on success. 322 * @return EINVAL if the map is not valid. 323 * @return EINVAL if the identifier parameter is NULL. 324 * @return EINVAL if the length parameter zero (0) and the 325 325 * identifier parameter is an empty character string (the 326 326 * first character is the terminating zero ('\0) character. 327 * @return sEEXIST if the key character string is already used.328 * @return sOther error codes as defined for the char_map_add_item()327 * @return EEXIST if the key character string is already used. 328 * @return Other error codes as defined for the char_map_add_item() 329 329 * function. 330 330 */ -
uspace/lib/c/generic/adt/dynamic_fifo.c
rcc3c2a1c r1bfd3d3 56 56 * 57 57 * @param[in] fifo The dynamic queue. 58 * @return sTRUE if the queue is valid.59 * @return sFALSE otherwise.58 * @return TRUE if the queue is valid. 59 * @return FALSE otherwise. 60 60 */ 61 61 static int dyn_fifo_is_valid(dyn_fifo_t *fifo) … … 68 68 * @param[in,out] fifo The dynamic queue. 69 69 * @param[in] size The initial queue size. 70 * @return sEOK on success.71 * @return sEINVAL if the queue is not valid.72 * @return sEBADMEM if the fifo parameter is NULL.73 * @return sENOMEM if there is not enough memory left.70 * @return EOK on success. 71 * @return EINVAL if the queue is not valid. 72 * @return EBADMEM if the fifo parameter is NULL. 73 * @return ENOMEM if there is not enough memory left. 74 74 */ 75 75 int dyn_fifo_initialize(dyn_fifo_t *fifo, int size) … … 100 100 * this limit. May be zero or negative to indicate no 101 101 * limit. 102 * @return sEOK on success.103 * @return sEINVAL if the queue is not valid.104 * @return sENOMEM if there is not enough memory left.102 * @return EOK on success. 103 * @return EINVAL if the queue is not valid. 104 * @return ENOMEM if there is not enough memory left. 105 105 */ 106 106 int dyn_fifo_push(dyn_fifo_t *fifo, int value, int max_size) … … 150 150 * 151 151 * @param[in,out] fifo The dynamic queue. 152 * @return sValue of the first item in the queue.153 * @return sEINVAL if the queue is not valid.154 * @return sENOENT if the queue is empty.152 * @return Value of the first item in the queue. 153 * @return EINVAL if the queue is not valid. 154 * @return ENOENT if the queue is empty. 155 155 */ 156 156 int dyn_fifo_pop(dyn_fifo_t *fifo) … … 172 172 * 173 173 * @param[in,out] fifo The dynamic queue. 174 * @return siValue of the first item in the queue.175 * @return sEINVAL if the queue is not valid.176 * @return sENOENT if the queue is empty.174 * @return Value of the first item in the queue. 175 * @return EINVAL if the queue is not valid. 176 * @return ENOENT if the queue is empty. 177 177 */ 178 178 int dyn_fifo_value(dyn_fifo_t *fifo) … … 190 190 * 191 191 * @param[in,out] fifo The dynamic queue. 192 * @return sEOK on success.193 * @return sEINVAL if the queue is not valid.192 * @return EOK on success. 193 * @return EINVAL if the queue is not valid. 194 194 */ 195 195 int dyn_fifo_destroy(dyn_fifo_t *fifo) -
uspace/lib/c/generic/adt/measured_strings.c
rcc3c2a1c r1bfd3d3 55 55 * appended with the terminating zero ('\0') character 56 56 * otherwise. 57 * @return sThe new bundled character string with measured length.58 * @return sNULL if there is not enough memory left.57 * @return The new bundled character string with measured length. 58 * @return NULL if there is not enough memory left. 59 59 */ 60 60 measured_string_t * … … 84 84 * 85 85 * @param[in] source The source measured string to be copied. 86 * @return sThe copy of the given measured string.87 * @return sNULL if the source parameter is NULL.88 * @return sNULL if there is not enough memory left.86 * @return The copy of the given measured string. 87 * @return NULL if the source parameter is NULL. 88 * @return NULL if there is not enough memory left. 89 89 */ 90 90 measured_string_t *measured_string_copy(measured_string_t *source) … … 120 120 * actual character strings. 121 121 * @param[in] count The size of the measured strings array. 122 * @return sEOK on success.123 * @return sEINVAL if the strings or data parameter is NULL.124 * @return sEINVAL if the count parameter is zero (0).125 * @return sEINVAL if the sent array differs in size.126 * @return sEINVAL if there is inconsistency in sent measured122 * @return EOK on success. 123 * @return EINVAL if the strings or data parameter is NULL. 124 * @return EINVAL if the count parameter is zero (0). 125 * @return EINVAL if the sent array differs in size. 126 * @return EINVAL if there is inconsistency in sent measured 127 127 * strings' lengths (should not occur). 128 * @return sENOMEM if there is not enough memory left.129 * @return sOther error codes as defined for the128 * @return ENOMEM if there is not enough memory left. 129 * @return Other error codes as defined for the 130 130 * async_data_write_finalize() function. 131 131 */ … … 209 209 * @param[in] strings The measured strings array to be processed. 210 210 * @param[in] count The measured strings array size. 211 * @return sThe computed sizes array.212 * @return sNULL if there is not enough memory left.211 * @return The computed sizes array. 212 * @return NULL if there is not enough memory left. 213 213 */ 214 214 static size_t *prepare_lengths(const measured_string_t *strings, size_t count) … … 238 238 * @param[in] strings The measured strings array to be transferred. 239 239 * @param[in] count The measured strings array size. 240 * @return sEOK on success.241 * @return sEINVAL if the strings parameter is NULL.242 * @return sEINVAL if the count parameter is zero (0).243 * @return sEINVAL if the calling module does not accept the given240 * @return EOK on success. 241 * @return EINVAL if the strings parameter is NULL. 242 * @return EINVAL if the count parameter is zero (0). 243 * @return EINVAL if the calling module does not accept the given 244 244 * array size. 245 * @return sEINVAL if there is inconsistency in sent measured245 * @return EINVAL if there is inconsistency in sent measured 246 246 * strings' lengths (should not occur). 247 * @return sOther error codes as defined for the247 * @return Other error codes as defined for the 248 248 * async_data_read_finalize() function. 249 249 */ … … 302 302 * actual character strings. 303 303 * @param[in] count The size of the measured strings array. 304 * @return sEOK on success.305 * @return sEINVAL if the strings or data parameter is NULL.306 * @return sEINVAL if the phone or count parameter is not positive.307 * @return sEINVAL if the sent array differs in size.308 * @return sENOMEM if there is not enough memory left.309 * @return sOther error codes as defined for the304 * @return EOK on success. 305 * @return EINVAL if the strings or data parameter is NULL. 306 * @return EINVAL if the phone or count parameter is not positive. 307 * @return EINVAL if the sent array differs in size. 308 * @return ENOMEM if there is not enough memory left. 309 * @return Other error codes as defined for the 310 310 * async_data_read_start() function. 311 311 */ … … 378 378 * @param[in] strings The measured strings array to be transferred. 379 379 * @param[in] count The measured strings array size. 380 * @return sEOK on success.381 * @return sEINVAL if the strings parameter is NULL.382 * @return sEINVAL if the phone or count parameter is not positive.383 * @return sOther error codes as defined for the380 * @return EOK on success. 381 * @return EINVAL if the strings parameter is NULL. 382 * @return EINVAL if the phone or count parameter is not positive. 383 * @return Other error codes as defined for the 384 384 * async_data_write_start() function. 385 385 */
Note:
See TracChangeset
for help on using the changeset viewer.