home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / header45.zip / mailslot.h < prev    next >
C/C++ Source or Header  |  1999-04-29  |  6KB  |  142 lines

  1. /**************************************************************************/
  2. /*                                                                        */
  3. /*              IBM OS/2(tm) Local Area Network (LAN) Server              */
  4. /*                            Version 5.03                                */
  5. /*                   (C) Copyright IBM Corp. 1988, 1998                   */
  6. /*                  Licensed Materials - Property of IBM                  */
  7. /*                                                                        */
  8. /**************************************************************************/
  9. /********************************************************************/
  10.  
  11. /********************************************************************
  12.  *                                                                  *
  13.  *  About this file ...  MAILSLOT.H                                 *
  14.  *                                                                  *
  15.  *  This file contains information about the Mailslot APIs.         *
  16.  *                                                                  *
  17.  *      Function prototypes.                                        *
  18.  *                                                                  *
  19.  ********************************************************************/
  20.  
  21.  
  22. #ifndef NETMAILSLOT_INCLUDED
  23.  
  24. #define NETMAILSLOT_INCLUDED
  25.  
  26. #ifdef ANY_32_BIT
  27. #pragma pack(1)
  28. #endif
  29.  
  30.  
  31. /****************************************************************
  32.  *                                                              *
  33.  *               Function prototypes - Mailslot                 *
  34.  *                                                              *
  35.  ****************************************************************/
  36.  
  37. extern API_FUNCTION
  38.   DosMakeMailslot ( const unsigned char LSFAR * pszName,
  39.                     unsigned short              cbMessageSize,
  40.                     unsigned short              cbMailslotSize,
  41.                     unsigned LSINT LSFAR *      phMailslot );
  42.  
  43. extern API_FUNCTION
  44.   DosDeleteMailslot ( unsigned LSINT hMailslot );
  45.  
  46. extern API_FUNCTION
  47.   DosMailslotInfo ( unsigned LSINT         hMailslot,
  48.                     unsigned short LSFAR * pcbMessageSize,
  49.                     unsigned short LSFAR * pcbMailslotSize,
  50.                     unsigned short LSFAR * pcbNextSize,
  51.                     unsigned short LSFAR * pusNextPriority,
  52.                     unsigned short LSFAR * pcMessages);
  53.  
  54. extern API_FUNCTION
  55.   DosPeekMailslot ( unsigned  LSINT        hMailslot,
  56.                     unsigned char LSFAR *  pbBuffer,
  57.                     unsigned short LSFAR * pcbReturned,
  58.                     unsigned short LSFAR * pcbNextSize,
  59.                     unsigned short LSFAR * pusNextPriority );
  60.  
  61. extern API_FUNCTION
  62.   DosReadMailslot ( unsigned  LSINT        hMailslot,
  63.                     unsigned char LSFAR *  pbBuffer,
  64.                     unsigned short LSFAR * pcbReturned,
  65.                     unsigned short LSFAR * pcbNextSize,
  66.                     unsigned short LSFAR * pusNextPriority,
  67.                     long                   cTimeout );
  68.  
  69. extern API_FUNCTION
  70.   DosWriteMailslot ( const unsigned char LSFAR * pszName,
  71.                      const unsigned char LSFAR * pbBuffer,
  72.                      unsigned short              cbBuffer,
  73.                      unsigned short              usPriority,
  74.                      unsigned short              usClass,
  75.                      long                        cTimeout );
  76.  
  77.  
  78.  
  79. #ifdef PURE_32
  80. /****************************************************************
  81.  *                                                              *
  82.  *               Function prototypes - Mailslot                 *
  83.  *                                                              *
  84.  ****************************************************************/
  85.  
  86. extern API32_FUNCTION
  87. Dos32MakeMailslot ( const unsigned char * pszName,
  88.                     unsigned long         ulMessageSize,  /* was USHORT*/
  89.                     unsigned long         ulMailslotSize, /* was USHORT*/
  90.                     unsigned long       * phMailslot );  /* was unsigned LSINT*/
  91.  
  92. extern API32_FUNCTION
  93. Dos32DeleteMailslot ( unsigned long  hMailslot );
  94.  
  95. extern API32_FUNCTION
  96. Dos32MailslotInfo ( unsigned long    hMailslot,        /* was unsigned LSINT */
  97.                     unsigned long  * pulMessageSize,   /* was USHORT */
  98.                     unsigned long  * pulMailslotSize,  /* was USHORT */
  99.                     unsigned long  * pulNextSize,      /* was USHORT */
  100.                     unsigned long  * pulNextPriority,  /* was USHORT */
  101.                     unsigned long  * pulMessages);     /* was USHORT */
  102.  
  103. extern API32_FUNCTION
  104. Dos32PeekMailslot ( unsigned long    hMailslot,        /* was unsigned LSINT */
  105.                     unsigned char  * pbBuffer,
  106.                     unsigned long  * pulReturned,      /* was USHORT */
  107.                     unsigned long  * pulNextSize,      /* was USHORT */
  108.                     unsigned long  * pulNextPriority); /* was USHORT */
  109.  
  110. extern API32_FUNCTION
  111. Dos32ReadMailslot ( unsigned long    hMailslot,        /* was unsigned LSINT */
  112.                     unsigned char  * pbBuffer,
  113.                     unsigned long  * pulReturned,      /* was USHORT */
  114.                     unsigned long  * pulNextSize,      /* was USHORT */
  115.                     unsigned long  * pulNextPriority,  /* was USHORT */
  116.                     long             lTimeout );
  117.  
  118. extern API32_FUNCTION
  119. Dos32WriteMailslot ( const unsigned char * pszName,
  120.                      const unsigned char * pbBuffer,
  121.                      unsigned long         ulBuffer,     /* was USHORT */
  122.                      unsigned long         ulPriority,   /* was USHORT */
  123.                      unsigned long         ulClass,      /* was USHORT */
  124.                      long                  lTimeout );
  125. #endif /* PURE_32 */
  126.  
  127.  
  128. /****************************************************************
  129.  *                                                              *
  130.  *              Special values and constants - Mailslot         *
  131.  *                                                              *
  132.  ****************************************************************/
  133.  
  134. #define MAILSLOT_NO_TIMEOUT     -1
  135.  
  136. #ifdef ANY_32_BIT
  137. #pragma pack()
  138. #endif
  139.  
  140. #endif /* NETMAILSLOT_INCLUDED */
  141.  
  142.