home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / dsstlkt5.zip / dssos2tk / dss / NETSTATS.H < prev    next >
C/C++ Source or Header  |  1998-05-08  |  9KB  |  210 lines

  1. /**************************************************************************/
  2. /*                                                                        */
  3. /*              IBM OS/2(tm) Directory and Security Services (DSS)        */
  4. /*                            Version 5.0                                 */
  5. /*                   (C) Copyright IBM Corp. 1995                         */
  6. /*                  Licensed Materials - Property of IBM                  */
  7. /*                                                                        */
  8. /**************************************************************************/
  9. /********************************************************************/
  10.  
  11. /********************************************************************
  12.  *                                    *
  13.  *  About this file ...  NETSTATS.H                    *
  14.  *                                    *
  15.  *  This file contains information about the NetStatistics APIs.    *
  16.  *                                    *
  17.  *    Function prototypes.                        *
  18.  *                                    *
  19.  *    Data structure templates.                    *
  20.  *                                    *
  21.  *    Definition of special values.                    *
  22.  *                                    *
  23.  *                                    *
  24.  *  NOTE:  You must include NETCONS.H before this file, since this  *
  25.  *       file    depends on values defined in NETCONS.H.            *
  26.  *                                    *
  27.  ********************************************************************/
  28.  
  29.  
  30. #ifdef  ANY_32_BIT
  31. #pragma pack(1)
  32. #endif
  33.  
  34.  
  35.  
  36. #ifndef NETSTATS_INCLUDED
  37.  
  38. #define NETSTATS_INCLUDED
  39. #define NETSTATS_INC
  40.  
  41.  
  42. /****************************************************************
  43.  *                                                              *
  44.  *              Function prototypes                             *
  45.  *                                                              *
  46.  ****************************************************************/
  47.  
  48. extern API_FUNCTION
  49.   NetStatisticsClear ( const unsigned char LSFAR * pszServer );
  50.  
  51. extern API_FUNCTION
  52.   NetStatisticsGet ( const unsigned char LSFAR *     pszServer,
  53.                      unsigned char LSFAR *           pbBuffer,
  54.                      unsigned short         cbBuffer,
  55.                      unsigned short LSFAR * pcbReturned,
  56.                      unsigned short LSFAR * pcbTotalAvail );
  57.  
  58. extern API_FUNCTION
  59.   NetStatisticsGet2 ( const unsigned char LSFAR *     pszServer,
  60.                       const unsigned char LSFAR *     pszService,
  61.                       unsigned long          ulReserved,
  62.                       short                  sLevel,
  63.                       unsigned long          flOptions,
  64.                       unsigned char LSFAR *           pbBuffer,
  65.                       unsigned short         cbBuffer,
  66.                       unsigned short LSFAR * pcbTotalAvail );
  67.  
  68.  
  69. #ifdef PURE_32
  70. /****************************************************************
  71.  *                                                              *
  72.  *                Function prototypes                           *
  73.  *           For "pure" 32-bit applications                     *
  74.  *                                                              *
  75.  ****************************************************************/
  76.  
  77. extern API32_FUNCTION
  78.   Net32StatisticsGet2 ( const unsigned char * pszServer,
  79.                         const unsigned char * pszService,
  80.                         unsigned long         ulReserved,
  81.                         unsigned long         ulLevel,      /*was signed short*/
  82.                         unsigned long         flOptions,
  83.                         unsigned char       * pbBuffer,
  84.                         unsigned long         ulBuffer,        /*was USHORT*/
  85.                         unsigned long       * pulTotalAvail ); /*was PUSHORT*/
  86. #endif /* PURE_32 */
  87.  
  88.  
  89. /****************************************************************
  90.  *                                *
  91.  *          Special values and constants            *
  92.  *                                *
  93.  ****************************************************************/
  94.  
  95.  
  96. #define STATSOPT_CLR    1
  97. #define STATS_NO_VALUE    ((unsigned long) -1L)
  98. #define STATS_OVERFLOW    ((unsigned long) -2L)
  99.  
  100.  
  101. /****************************************************************
  102.  *                                *
  103.  *          Data structure templates            *
  104.  *                                *
  105.  ****************************************************************/
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112. struct statistics_info_0 {
  113.     unsigned long   st0_start;        /* time statistics collection started   */
  114.     unsigned long   st0_wknumNCBs;    /* # workstation NCBs issued            */
  115.     unsigned long   st0_wkfiNCBs;     /* # workstation NCBs failed issue      */
  116.     unsigned long   st0_wkfcNCBs;     /* # workstation NCBs failed completion */
  117.     unsigned long   st0_wksesstart;   /* # workstation sessions started       */
  118.     unsigned long   st0_wksessfail;   /* # workstation session failures       */
  119.     unsigned long   st0_wkuses;       /* # workstation uses                   */
  120.     unsigned long   st0_wkusefail;    /* # workstation use failures           */
  121.     unsigned long   st0_wkautorec;    /* # workstation auto-reconnects        */
  122.     unsigned long   st0_rdrnumNCBs;   /* # redir NCBs issued              */
  123.     unsigned long   st0_srvnumNCBs;   /* # NCBs issued for the server          */
  124.     unsigned long   st0_usrnumNCBs;   /* # user NCBs issued              */
  125.     unsigned long   st0_reserved4;    /* reserved for future use              */
  126.     unsigned long   st0_reserved5;    /* reserved for future use              */
  127.     unsigned long   st0_reserved6;    /* reserved for future use              */
  128.     unsigned long   st0_reserved7;    /* reserved for future use              */
  129.     unsigned long   st0_reserved8;    /* reserved for future use              */
  130.     unsigned long   st0_svfopens;     /* # of server file opens               */
  131.     unsigned long   st0_svdevopens;   /* # of server device opens             */
  132.     unsigned long   st0_svjobsqueued; /* # of server print jobs spooled       */
  133.     unsigned long   st0_svsopens;     /* # of server session starts           */
  134.     unsigned long   st0_svstimedout;  /* # of server session auto-disconnects */
  135.     unsigned long   st0_svserrorout;  /* # of server sessions errored out     */
  136.     unsigned long   st0_svpwerrors;   /* # of server password violations      */
  137.     unsigned long   st0_svpermerrors; /* # of server access permission errors */
  138.     unsigned long   st0_svsyserrors;  /* # of server system errors            */
  139.     unsigned long   st0_svbytessent;  /* # of server bytes sent to net        */
  140.     unsigned long   st0_svbytesrcvd;  /* # of server bytes received from net  */
  141.     unsigned long   st0_svavresponse; /* average server response time in msec */
  142. }; /* statistics_info_0 */
  143.  
  144.  
  145.  
  146. struct stat_workstation_0  {
  147.         unsigned long  stw0_start;
  148.         unsigned long  stw0_numNCB_r;
  149.         unsigned long  stw0_numNCB_s;
  150.         unsigned long  stw0_numNCB_a;
  151.         unsigned long  stw0_fiNCB_r;
  152.         unsigned long  stw0_fiNCB_s;
  153.         unsigned long  stw0_fiNCB_a;
  154.         unsigned long  stw0_fcNCB_r;
  155.         unsigned long  stw0_fcNCB_s;
  156.         unsigned long  stw0_fcNCB_a;
  157.         unsigned long  stw0_sesstart;
  158.         unsigned long  stw0_sessfailcon;
  159.         unsigned long  stw0_sessbroke;
  160.         unsigned long  stw0_uses;
  161.         unsigned long  stw0_usefail;
  162.         unsigned long  stw0_autorec;
  163.         unsigned long  stw0_bytessent_r_lo;
  164.         unsigned long  stw0_bytessent_r_hi;
  165.         unsigned long  stw0_bytesrcvd_r_lo;
  166.         unsigned long  stw0_bytesrcvd_r_hi;
  167.         unsigned long  stw0_bytessent_s_lo;
  168.         unsigned long  stw0_bytessent_s_hi;
  169.         unsigned long  stw0_bytesrcvd_s_lo;
  170.         unsigned long  stw0_bytesrcvd_s_hi;
  171.         unsigned long  stw0_bytessent_a_lo;
  172.         unsigned long  stw0_bytessent_a_hi;
  173.         unsigned long  stw0_bytesrcvd_a_lo;
  174.         unsigned long  stw0_bytesrcvd_a_hi;
  175.         unsigned long  stw0_reqbufneed;
  176.         unsigned long  stw0_bigbufneed;
  177. }; /* stat_workstation_0 */
  178.  
  179.  
  180. struct stat_server_0  {
  181.         unsigned long  sts0_start;
  182.         unsigned long  sts0_fopens;
  183.         unsigned long  sts0_devopens;
  184.         unsigned long  sts0_jobsqueued;
  185.         unsigned long  sts0_sopens;
  186.         unsigned long  sts0_stimedout;
  187.         unsigned long  sts0_serrorout;
  188.         unsigned long  sts0_pwerrors;
  189.         unsigned long  sts0_permerrors;
  190.         unsigned long  sts0_syserrors;
  191.         unsigned long  sts0_bytessent_low;
  192.         unsigned long  sts0_bytessent_high;
  193.         unsigned long  sts0_bytesrcvd_low;
  194.         unsigned long  sts0_bytesrcvd_high;
  195.         unsigned long  sts0_avresponse;
  196.         unsigned long  sts0_reqbufneed;
  197.         unsigned long  sts0_bigbufneed;
  198. }; /* stat_server_0 */
  199.  
  200.  
  201. #endif /* NETSTATS_INCLUDED */
  202.  
  203. #ifdef  ANY_32_BIT
  204. /*#pragma linkage (NetStatisticsClear, far16 pascal) */
  205. /*#pragma linkage (NetStatisticsGet, far16 pascal) */
  206. /*#pragma linkage (NetStatisticsGet2, far16 pascal) */
  207. #pragma pack()
  208. #endif
  209.  
  210.