Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

101 lines
1.6 KiB

  1. //+--------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1996-1998
  5. //
  6. // File: utils.cpp
  7. //
  8. // Contents: Hydra License Server Service Control Manager Interface
  9. //
  10. // History: 12-09-97 HueiWang Modified from MSDN RPC Service Sample
  11. //
  12. //---------------------------------------------------------------------------
  13. #ifndef __LS_UTILS_H
  14. #define __LS_UTILS_H
  15. #include <windows.h>
  16. #include <stdio.h>
  17. #ifdef __cplusplus
  18. extern "C" {
  19. #endif
  20. void
  21. TLSLogInfoEvent(
  22. DWORD
  23. );
  24. void
  25. TLSLogWarningEvent(
  26. DWORD
  27. );
  28. void
  29. TLSLogErrorEvent(
  30. DWORD
  31. );
  32. void
  33. TLSLogEvent(
  34. DWORD,
  35. DWORD,
  36. DWORD, ...
  37. );
  38. void
  39. TLSLogEventString(
  40. IN DWORD dwType,
  41. IN DWORD dwEventId,
  42. IN WORD wNumString,
  43. IN LPCTSTR* lpStrings
  44. );
  45. BOOL
  46. LoadResourceString(
  47. DWORD dwId,
  48. LPTSTR szBuf,
  49. DWORD dwBufSize
  50. );
  51. BOOL
  52. APIENTRY
  53. TLSCheckTokenMembership(
  54. IN HANDLE TokenHandle OPTIONAL,
  55. IN PSID SidToCheck,
  56. OUT PBOOL IsMember
  57. );
  58. DWORD
  59. IsAdmin(
  60. BOOL* bMember
  61. );
  62. void
  63. UnixTimeToFileTime(
  64. time_t t,
  65. LPFILETIME pft
  66. );
  67. BOOL
  68. FileTimeToLicenseDate(
  69. LPFILETIME pft,
  70. DWORD* t
  71. );
  72. BOOL
  73. TLSSystemTimeToFileTime(
  74. SYSTEMTIME* pSysTime,
  75. LPFILETIME pfTime
  76. );
  77. BOOL
  78. FileExists(
  79. IN PCTSTR FileName,
  80. OUT PWIN32_FIND_DATA FindData OPTIONAL
  81. );
  82. #ifdef __cplusplus
  83. }
  84. #endif
  85. #endif