home *** CD-ROM | disk | FTP | other *** search
/ Network Support Encyclopedia 96-1 / novell-nsepro-1996-1-cd2.iso / download / netware / os232.exe / INCLUDE / NWCLXCON.H < prev    next >
C/C++ Source or Header  |  1995-07-10  |  9KB  |  294 lines

  1. /****************************************************************************
  2.  
  3.   $Workfile:   nwclxcon.h  $
  4.   $Revision:   1.3  $
  5.   $Modtime::   05 Jul 1995 17:15:40                        $
  6.   $Copyright:
  7.  
  8.   Copyright (c) 1989-1995 Novell, Inc.  All Rights Reserved.
  9.  
  10.   THIS WORK IS  SUBJECT  TO  U.S.  AND  INTERNATIONAL  COPYRIGHT  LAWS  AND
  11.   TREATIES.   NO  PART  OF  THIS  WORK MAY BE  USED,  PRACTICED,  PERFORMED
  12.   COPIED, DISTRIBUTED, REVISED, MODIFIED, TRANSLATED,  ABRIDGED, CONDENSED,
  13.   EXPANDED,  COLLECTED,  COMPILED,  LINKED,  RECAST, TRANSFORMED OR ADAPTED
  14.   WITHOUT THE PRIOR WRITTEN CONSENT OF NOVELL, INC. ANY USE OR EXPLOITATION
  15.   OF THIS WORK WITHOUT AUTHORIZATION COULD SUBJECT THE PERPETRATOR TO
  16.   CRIMINAL AND CIVIL LIABILITY.$
  17.  
  18.  ***************************************************************************/
  19.  
  20. #if ! defined ( NWCLXCON_H )
  21. #define NWCLXCON_H
  22.  
  23. #if ! defined ( NTYPES_H )
  24. #include "ntypes.h"
  25. #endif
  26.  
  27. #if ! defined ( NWAPIDEF_H )
  28. #include "nwapidef.h"
  29. #endif
  30.  
  31. #include "npackon.h"
  32.  
  33. /* Authentication States */
  34. #define NWCC_AUTHENT_STATE_NONE     0x0000
  35. #define NWCC_AUTHENT_STATE_BIND     0x0001
  36. #define NWCC_AUTHENT_STATE_NDS      0x0002
  37.  
  38. /* Broadcast States */
  39. #define NWCC_BCAST_PERMIT_ALL       0x0000
  40. #define NWCC_BCAST_PERMIT_SYSTEM    0x0001
  41. #define NWCC_BCAST_PERMIT_NONE      0x0002
  42. #define NWCC_BCAST_PERMIT_POLL      0x0003  /* DOS Windows and OS/2 only */
  43.  
  44. /* NDS States */
  45. #define NWCC_NDS_NOT_CAPABLE        0x0000
  46. #define NWCC_NDS_CAPABLE            0x0001
  47.  
  48. /* License States */
  49. #define NWCC_NOT_LICENSED           0x0000
  50. #define NWCC_CONNECTION_LICENSED    0x0001
  51. #define NWCC_HANDLE_LICENSED        0x0002
  52.  
  53. /* Name Format types */
  54. #define NWCC_NAME_FORMAT_NDS        0x0001  /* Unicode full dot format name */
  55. #define NWCC_NAME_FORMAT_BIND       0x0002
  56. #define NWCC_NAME_FORMAT_NDS_TREE   0x0008
  57.  
  58. /* Transport types */
  59. #define NWCC_TRAN_TYPE_IPX          0x00000001
  60. #define NWCC_TRAN_TYPE_UDP          0x00000002
  61. #define NWCC_TRAN_TYPE_DDP          0x00000003
  62. #define NWCC_TRAN_TYPE_ASP          0x00000004
  63.  
  64. /* Open States */
  65. #define NWCC_OPEN_LICENSED          0x0001
  66. #define NWCC_OPEN_UNLICENSED        0x0002
  67.  
  68. /* Reserved Value */
  69. #define NWCC_RESERVED               0x0000
  70.  
  71. typedef struct tagNWCCTranAddr
  72. {
  73.    nuint32  type;
  74.    nuint32  len;
  75.    pnuint8  buffer;
  76. } NWCCTranAddr, N_FAR *pNWCCTranAddr;
  77.  
  78. typedef struct tagNWCCVersion
  79. {
  80.    nuint major;
  81.    nuint minor;
  82.    nuint revision;
  83. }NWCCVersion, N_FAR *pNWCCVersion;
  84.  
  85. /* Info Types */
  86. #define NWCC_INFO_AUTHENT_STATE      1
  87. #define NWCC_INFO_BCAST_STATE        2
  88. #define NWCC_INFO_CONN_REF           3
  89. #define NWCC_INFO_TREE_NAME          4
  90. #define NWCC_INFO_CONN_NUMBER        5
  91. #define NWCC_INFO_USER_ID            6
  92. #define NWCC_INFO_SERVER_NAME        7
  93. #define NWCC_INFO_NDS_STATE          8
  94. #define NWCC_INFO_MAX_PACKET_SIZE    9
  95. #define NWCC_INFO_LICENSE_STATE     10
  96. #define NWCC_INFO_DISTANCE          11
  97. #define NWCC_INFO_SERVER_VERSION    12
  98.  
  99. /* Current Info Version */
  100. #define NWCC_INFO_VERSION           0x0001
  101.  
  102. /* Transport Address is not returned in this structure */
  103. typedef struct tagNWCCConnInfo
  104. {
  105.    nuint       authenticationState;
  106.    nuint       broadcastState;
  107.    nuint32     connRef;
  108.    nstr        treeName[NWA_MAX_TREE_NAME_LEN];
  109.    nuint       connNum;
  110.    nuint32     userID;
  111.    nstr        serverName[NWA_MAX_SERVER_NAME_LEN];
  112.    nuint       NDSState;
  113.    nuint       maxPacketSize;
  114.    nuint       licenseState;
  115.    nuint       distance;
  116.    NWCCVersion serverVersion;
  117. }NWCCConnInfo, N_FAR *pNWCCConnInfo;
  118.  
  119. #ifdef __cplusplus
  120. extern "C" {
  121. #endif
  122.  
  123. N_EXTERN_LIBRARY( NWRCODE )
  124. NWCCOpenConnByName
  125. (
  126.    NWCONN_HANDLE           startConnHandle,     /* in     */
  127.    pnstr8                  name,                /* in     */
  128.    nuint                   nameFormat,          /* in     */
  129.    nuint                   openState,           /* in     */
  130.    nuint                   reserved,            /* in     * use NWCC_RESERVED */
  131.    NWCONN_HANDLE N_FAR *   connHandle           /*    out */
  132. );
  133.  
  134. N_EXTERN_LIBRARY( NWRCODE )
  135. NWCCOpenConnByAddr
  136. (
  137.    pNWCCTranAddr           tranAddr,            /* in     */
  138.    nuint                   openState,           /* in     */
  139.    nuint                   reserved,            /* in     * use NWCC_RESERVED */
  140.    NWCONN_HANDLE N_FAR *   connHandle           /*    out */
  141. );
  142.  
  143. N_EXTERN_LIBRARY( NWRCODE )
  144. NWCCOpenConnByRef
  145. (
  146.    nuint32                 connRef,             /* in     */
  147.    nuint                   openState,           /* in     */
  148.    nuint                   reserved,            /* in     * use NWCC_RESERVED */
  149.    NWCONN_HANDLE N_FAR *   connHandle           /*    out */          
  150. );
  151.  
  152. N_EXTERN_LIBRARY( NWRCODE )
  153. NWCCCloseConn
  154. (
  155.    NWCONN_HANDLE  connHandle                    /* in     */
  156. );
  157.  
  158. N_EXTERN_LIBRARY( NWRCODE )
  159. NWCCSysCloseConnRef
  160. (
  161.    nuint32       connRef                        /* in     */
  162. );
  163.  
  164. N_EXTERN_LIBRARY( NWRCODE )
  165. NWCCMakeConnPermanent
  166. (
  167.    NWCONN_HANDLE  connHandle                    /* in     */
  168. );
  169.  
  170. N_EXTERN_LIBRARY( NWRCODE )
  171. NWCCLicenseConn
  172. (
  173.    NWCONN_HANDLE  connHandle                    /* in     */
  174. );
  175.  
  176. N_EXTERN_LIBRARY( NWRCODE )
  177. NWCCUnlicenseConn
  178. (
  179.    NWCONN_HANDLE  connHandle                    /* in     */
  180. );
  181.  
  182. N_EXTERN_LIBRARY( NWRCODE )
  183. NWCCGetConnRef
  184. (
  185.    NWCONN_HANDLE  connHandle,                   /* in     */
  186.    pnuint32       connRef                       /*    out */
  187. );
  188.  
  189. N_EXTERN_LIBRARY( NWRCODE )
  190. NWCCGetPrefServerName
  191. (
  192.    nuint    len,                                /* in     */
  193.    pnstr    prefServer                          /*    out */
  194. );
  195.  
  196. N_EXTERN_LIBRARY( NWRCODE )
  197. NWCCSetPrefServerName
  198. (
  199.    pnstr    prefServer                          /* in     */
  200. );
  201.  
  202. N_EXTERN_LIBRARY( NWRCODE )
  203. NWCCGetPrimConnRef
  204. (
  205.    pnuint32 connRef                             /*    out */
  206. );
  207.  
  208. N_EXTERN_LIBRARY( NWRCODE )
  209. NWCCSetPrimConn
  210. (
  211.    NWCONN_HANDLE  connHandle                    /* in     */
  212. );
  213.  
  214. N_EXTERN_LIBRARY( NWRCODE )
  215. NWCCScanConnRefs
  216. (  
  217.    pnuint32    scanIterator,                    /* in/out : initialize to 0 */
  218.    pnuint32    connRef                          /*    out */
  219. );
  220.  
  221. N_EXTERN_LIBRARY( NWRCODE )
  222. NWCCGetConnInfo
  223. (
  224.    NWCONN_HANDLE  connHandle,                   /* in     */
  225.    nuint          infoType,                     /* in     */
  226.    nuint          len,                          /* in     */
  227.    nptr           buffer                        /*    out */
  228. ); 
  229.  
  230. N_EXTERN_LIBRARY( NWRCODE )
  231. NWCCGetConnRefInfo
  232. (
  233.    nuint32        connRef,                      /* in     */
  234.    nuint          infoType,                     /* in     */
  235.    nuint          len,                          /* in     */
  236.    nptr           buffer                        /*    out */
  237. ); 
  238.  
  239. N_EXTERN_LIBRARY( NWRCODE )
  240. NWCCGetAllConnInfo
  241. (
  242.    NWCONN_HANDLE  connHandle,                /* in     */
  243.    nuint          connInfoVersion,           /* in     */
  244.                                              /* always set to NWCC_INFO_VERSION */
  245.    pNWCCConnInfo  connInfoBuffer             /*    out */
  246. ); 
  247.  
  248. N_EXTERN_LIBRARY( NWRCODE )
  249. NWCCGetAllConnRefInfo
  250. (
  251.    nuint32        connRef,                   /* in     */
  252.    nuint          connInfoVersion,           /* in     */
  253.                                              /* always set to NWCC_INFO_VERSION */
  254.    pNWCCConnInfo  connInfoBuffer             /*    out */
  255. ); 
  256.  
  257. N_EXTERN_LIBRARY( NWRCODE )
  258. NWCCGetConnAddressLength
  259. (
  260.    NWCONN_HANDLE  connHandle,                /* in     */
  261.    pnuint32       addrLen                    /*    out */
  262. );
  263.  
  264. N_EXTERN_LIBRARY( NWRCODE )
  265. NWCCGetConnRefAddressLength
  266. (
  267.    nuint32           connRef,                /* in     */
  268.    pnuint32          addrLen                 /*    out */
  269. );
  270.  
  271.  
  272. N_EXTERN_LIBRARY( NWRCODE )
  273. NWCCGetConnAddress
  274. (
  275.    NWCONN_HANDLE  connHandle,                /* in     */
  276.    nuint32        bufferLen,                 /* in     */
  277.    pNWCCTranAddr  tranAddr                   /*    out */
  278. ); 
  279.  
  280. N_EXTERN_LIBRARY( NWRCODE )
  281. NWCCGetConnRefAddress
  282. (
  283.    nuint32        connRef,                   /* in     */
  284.    nuint32        bufferLen,                 /* in     */
  285.    pNWCCTranAddr  tranAddr                   /*    out */
  286. ); 
  287.  
  288. #ifdef __cplusplus
  289. }
  290. #endif
  291.  
  292. #include "npackoff.h"
  293. #endif /* NWCLXCON_INC */
  294.