VirtualBox

Changeset 26702 in vbox


Ignore:
Timestamp:
Feb 23, 2010 1:35:59 PM (15 years ago)
Author:
vboxsync
Message:

iprt/types.h,iprt/pipe.h: Added pipe.h (no code yet) and preparing for polling and RTProcCreateEx.

Location:
trunk/include/iprt
Files:
1 added
1 edited

Legend:

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

    r26683 r26702  
    11551155#define NIL_RTNATIVETHREAD                          (~(RTNATIVETHREAD)0)
    11561156
     1157/** Pipe handle. */
     1158typedef RTHCUINTPTR                                 RTPIPE;
     1159/** Pointer to a pipe handle. */
     1160typedef RTPIPE                                     *PRTPIPE;
     1161/** Nil pipe handle.
     1162 * @remarks This is not 0 because because of UNIX and OS/2 handle values.
     1163 *          Take care! */
     1164#define NIL_RTPIPE                                 (~(RTPIPE)0)
     1165
     1166/** @typedef RTPOLLSET
     1167 * Poll set handle. */
     1168typedef R3R0PTRTYPE(struct RTPOLLSETINTERNAL *)     RTPOLLSET;
     1169/** Pointer to a poll set handle. */
     1170typedef RTPOLLSET                                  *PRTPOLLSET;
     1171/** Nil poll set handle handle. */
     1172#define NIL_RTPOLLSET                               ((RTPOLLSET)0)
     1173
    11571174/** Process identifier. */
    11581175typedef uint32_t                                    RTPROCESS;
     
    13511368/** The default string cache handle. */
    13521369#define RTSTRCACHE_DEFAULT                          ((RTSTRCACHE)-2)
     1370
     1371/**
     1372 * Handle type.
     1373 *
     1374 * This is usually used together with RTHANDLEUNION.
     1375 */
     1376typedef enum RTHANDLETYPE
     1377{
     1378    /** The invalid zero value. */
     1379    RTHANDLETYPE_INVALID = 0,
     1380    /** File handle. */
     1381    RTHANDLETYPE_FILE,
     1382    /** Pipe handle */
     1383    RTHANDLETYPE_PIPE,
     1384    /** Socket handle. */
     1385    RTHANDLETYPE_SOCKET,
     1386    /** Thread handle. */
     1387    RTHANDLETYPE_THREAD,
     1388    /** The end of the valid values. */
     1389    RTHANDLETYPE_END,
     1390    /** The 32-bit type blow up. */
     1391    RTHANDLETYPE_32BIT_HACK = 0x7fffffff
     1392} RTHANDLETYPE;
     1393/** Pointer to a handle type. */
     1394typedef RTHANDLETYPE *PRTHANDLETYPE;
     1395
     1396/**
     1397 * Handle union.
     1398 *
     1399 * This is usually used together with RTHANDLETYPE or as RTHANDLE.
     1400 */
     1401typedef union RTHANDLEUNION
     1402{
     1403    RTFILE          hFile;              /**< File handle. */
     1404    RTPIPE          hPipe;              /**< Pipe handle. */
     1405    RTSOCKET        hSocket;            /**< Socket handle. */
     1406    RTTHREAD        hThread;            /**< Thread handle. */
     1407} RTHANDLEUNION;
     1408/** Pointer to a handle union. */
     1409typedef RTHANDLEUNION *PRTHANDLEUNION;
     1410/** Pointer to a const handle union. */
     1411typedef RTHANDLEUNION const *PCRTHANDLEUNION;
     1412
     1413/**
     1414 * Generic handle.
     1415 */
     1416typedef struct RTHANDLE
     1417{
     1418    /** The handle type. */
     1419    RTHANDLETYPE    enmType;
     1420    /** The handle value. */
     1421    RTHANDLEUNION   u;
     1422} RTHANDLE;
     1423/** Pointer to a generic handle. */
     1424typedef RTHANDLE *PRTHANDLE;
     1425/** Pointer to a const generic handle. */
     1426typedef RTHANDLE const *PCRTHANDLE;
    13531427
    13541428
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