VirtualBox

Changeset 39686 in vbox


Ignore:
Timestamp:
Dec 30, 2011 1:30:12 AM (13 years ago)
Author:
vboxsync
Message:

req.h: docs.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/req.h

    r39632 r39686  
    425425RTDECL(int) RTReqPoolAlloc(RTREQPOOL hPool, RTREQTYPE enmType, PRTREQ *phReq);
    426426
     427/**
     428 * Call a function on a worker thread.
     429 *
     430 * @returns IPRT status code.
     431 * @param   hPool           The request thread pool handle.
     432 * @param   cMillies        The number of milliseconds to wait for the request
     433 *                          to be processed.
     434 * @param   phReq           Where to return the request. Can be NULL if the
     435 *                          RTREQFLAGS_NO_WAIT flag is used.
     436 * @param   fFlags          A combination of RTREQFLAGS values.
     437 * @param   pfnFunction     The function to be called.  Must be declared by a
     438 *                          DECL macro because of calling conventions.
     439 * @param   cArgs           The number of arguments in the ellipsis.
     440 * @param   ...             Arguments.
     441 *
     442 * @remarks The function better avoid taking uint64_t and structs as part of the
     443 *          arguments (use pointers to these instead).  In general anything
     444 *          that's larger than an uintptr_t is problematic.
     445 */
    427446RTDECL(int) RTReqPoolCallEx( RTREQPOOL hPool, RTMSINTERVAL cMillies, PRTREQ *phReq, uint32_t fFlags, PFNRT pfnFunction, unsigned cArgs, ...);
     447
     448
     449/**
     450 * Call a function on a worker thread.
     451 *
     452 * @returns IPRT status code.
     453 * @param   hPool           The request thread pool handle.
     454 * @param   cMillies        The number of milliseconds to wait for the request
     455 *                          to be processed.
     456 * @param   phReq           Where to return the request. Can be NULL if the
     457 *                          RTREQFLAGS_NO_WAIT flag is used.
     458 * @param   fFlags          A combination of RTREQFLAGS values.
     459 * @param   pfnFunction     The function to be called.  Must be declared by a
     460 *                          DECL macro because of calling conventions.
     461 * @param   cArgs           The number of arguments in the variable argument
     462 *                          list.
     463 * @param   va              Arguments.
     464 * @remarks See remarks on RTReqPoolCallEx.
     465 */
    428466RTDECL(int) RTReqPoolCallExV(RTREQPOOL hPool, RTMSINTERVAL cMillies, PRTREQ *phReq, uint32_t fFlags, PFNRT pfnFunction, unsigned cArgs, va_list va);
    429467
     468/**
     469 * Call a function on a worker thread, wait for it to return.
     470 *
     471 * @returns IPRT status code returned by @a pfnFunction or request pool error.
     472 * @param   hPool           The request thread pool handle.
     473 * @param   pfnFunction     The function to be called.  Must be declared by a
     474 *                          DECL macro because of calling conventions.  The
     475 *                          function must return an int value compatible with
     476 *                          the IPRT status code convention.
     477 * @param   cArgs           The number of arguments in the elipsis.
     478 * @param   ...             Arguments.
     479 * @remarks See remarks on RTReqPoolCallEx.
     480 */
    430481RTDECL(int) RTReqPoolCallWait(RTREQPOOL hPool, PFNRT pfnFunction, unsigned cArgs, ...);
     482
     483/**
     484 * Call a function on a worker thread, don't wait for it to return.
     485 *
     486 * @returns IPRT status code.
     487 * @param   hPool           The request thread pool handle.
     488 * @param   pfnFunction     The function to be called.  Must be declared by a
     489 *                          DECL macro because of calling conventions.  The
     490 *                          function should return an int value compatible with
     491 *                          the IPRT status code convention, thought it's not
     492 *                          all that important as it's thrown away.
     493 * @param   cArgs           The number of arguments in the elipsis.
     494 * @param   ...             Arguments.
     495 * @remarks See remarks on RTReqPoolCallEx.
     496 */
    431497RTDECL(int) RTReqPoolCallNoWait(RTREQPOOL hPool, PFNRT pfnFunction, unsigned cArgs, ...);
    432498
     499/**
     500 * Call a void function on a worker thread.
     501 *
     502 * @returns IPRT status code.
     503 * @param   hPool           The request thread pool handle.
     504 * @param   pfnFunction     The function to be called.  Must be declared by a
     505 *                          DECL macro because of calling conventions.  The
     506 *                          function is taken to return void.
     507 * @param   cArgs           The number of arguments in the elipsis.
     508 * @param   ...             Arguments.
     509 * @remarks See remarks on RTReqPoolCallEx.
     510 */
    433511RTDECL(int) RTReqPoolCallVoidWait(RTREQPOOL hPool, PFNRT pfnFunction, unsigned cArgs, ...);
     512
     513/**
     514 * Call a void function on a worker thread, don't wait for it to return.
     515 *
     516 * @returns IPRT status code.
     517 * @param   hPool           The request thread pool handle.
     518 * @param   pfnFunction     The function to be called.  Must be declared by a
     519 *                          DECL macro because of calling conventions.  The
     520 *                          function is taken to return void.
     521 * @param   cArgs           The number of arguments in the elipsis.
     522 * @param   ...             Arguments.
     523 * @remarks See remarks on RTReqPoolCallEx.
     524 */
    434525RTDECL(int) RTReqPoolCallVoidNoWait(RTREQPOOL hPool, PFNRT pfnFunction, unsigned cArgs, ...);
    435526
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette