儲存庫 vbox 的更動 17094
- 時間撮記:
- 2009-2-24 下午08:08:18 (16 年 以前)
- 檔案:
-
- 修改 1 筆資料
圖例:
- 未更動
- 新增
- 刪除
-
trunk/include/iprt/getopt.h
r17092 r17094 197 197 int iFirst, uint32_t fFlags); 198 198 199 /* 199 /** 200 200 * Command line argument parser, handling both long and short options and checking 201 201 * argument formats, if desired. 202 202 * 203 203 * This is to be called in a loop until it returns 0 (meaning that all options 204 * were parsed) or a negative value (meaning that an error occured). The passed in 205 * argument vector is sorted into options and non-option arguments, such that when 206 * returning 0 the *piThis is the index of the first non-option argument. 204 * were parsed) or a negative value (meaning that an error occured). How non-option 205 * arguments are dealt with depends on the flags passed to RTGetOptInit. The default 206 * (fFlags = 0) is to return VINF_GETOPT_NOT_OPTION with pValueUnion->psz pointing to 207 * the argument string. 207 208 * 208 209 * For example, for a program which takes the following options: … … 265 266 * @endcode 266 267 * 267 * @param pState The state previously initialized with RTGetOptInit. 268 * @param pValueUnion Union with value; in the event of an error, psz member 268 * @returns 0 when done parsing. 269 * @returns IPRT error status on parse error. 270 * @returns VINF_GETOPT_NOT_OPTION when encountering a non-option argument and 271 * RTGETOPT_FLAG_SORT was not specified. pValueUnion->psz points to the 272 * argument string. 273 * @returns VERR_GETOPT_UNKNOWN_OPTION when encountering an unknown option. 274 * pValueUnion->psz points to the option string. 275 * @returns VERR_GETOPT_REQUIRED_ARGUMENT_MISSING and pValueUnion->pDef if 276 * a required argument (aka value) was missing for an option. 277 * @returns VERR_GETOPT_INVALID_ARGUMENT_FORMAT and pValueUnion->pDef if 278 * argument (aka value) convertion failed. 279 * 280 * @param pState The state previously initialized with RTGetOptInit. 281 * @param pValueUnion Union with value; in the event of an error, psz member 269 282 * points to erroneous parameter; otherwise, for options 270 283 * that require an argument, this contains the value of
注意:
瀏覽 TracChangeset
來幫助您使用更動檢視器