home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / sdk / winbase / winnt / pop3 / protos.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-10-05  |  2.1 KB  |  126 lines

  1.  
  2. /******************************************************************************\
  3. *       This is a part of the Microsoft Source Code Samples.
  4. *       Copyright (C) 1992-1997 Microsoft Corporation.
  5. *       All rights reserved. 
  6. *       This source code is only intended as a supplement to 
  7. *       Microsoft Development Tools and/or WinHelp documentation.
  8. *       See these sources for detailed information regarding the 
  9. *       Microsoft samples programs.
  10. \******************************************************************************/
  11.  
  12. //+---------------------------------------------------------------------------
  13. //
  14. //  File:       protos.h
  15. //
  16. //  Contents:
  17. //
  18. //  Classes:
  19. //
  20. //  Functions:
  21. //
  22. //----------------------------------------------------------------------------
  23.  
  24. #ifndef __PROTOS_H__
  25. #define __PROTOS_H__
  26.  
  27.  
  28.  
  29.  
  30. //
  31. // Service Controller interaction:
  32. //
  33.  
  34. BOOL
  35. NotifyServiceController(
  36.             VOID);
  37.  
  38. BOOL
  39. UpdateServiceStatus(DWORD   Status);
  40.  
  41. void
  42. FailServiceStart(
  43.     DWORD           Win32Code,
  44.     DWORD           PrivateCode);
  45.  
  46.  
  47. //
  48. // Event Logging Support
  49. //
  50.  
  51. BOOL
  52. InitializeEvents(void);
  53.  
  54. DWORD
  55. ReportServiceEvent(
  56.     IN WORD EventType,
  57.     IN DWORD EventId,
  58.     IN DWORD SizeOfRawData,
  59.     IN PVOID RawData,
  60.     IN DWORD NumberOfStrings,
  61.     ...
  62.     );
  63.  
  64.  
  65. //
  66. // Command dispatcher
  67. //
  68.  
  69. Pop3Disposition
  70. Pop3Dispatch(
  71.     PVOID       pContext,
  72.     PUCHAR      InputBuffer,
  73.     DWORD       InputBufferLen,
  74.     PHANDLE     SendHandle,
  75.     PUCHAR *    OutputBuffer,
  76.     PDWORD      OutputBufferLen
  77.     );
  78.  
  79. PVOID
  80. CreatePop3Context(void);
  81.  
  82. //
  83. // Parameter support:
  84. //
  85.  
  86. BOOL
  87. ReadParameters(VOID);
  88.  
  89.  
  90.  
  91. //
  92. // Service Support
  93. //
  94.  
  95. void
  96. WINAPI
  97. Pop3SrvMain(
  98.     DWORD       argc,
  99.     LPTSTR      argv[]);
  100.  
  101. //
  102. // Worker thread initialization routine.
  103. //
  104.  
  105. HANDLE
  106. InitializeThreads (
  107.     VOID
  108.     );
  109.  
  110. //
  111. // Connection management routines.
  112. //
  113.  
  114. BOOL
  115. AcceptClients (
  116.     HANDLE hCompletionPort
  117.     );
  118.  
  119. VOID
  120. CloseClient (
  121.     PCLIENT_CONTEXT lpClientContext,
  122.     BOOL bGraceful
  123.     );
  124.  
  125. #endif
  126.