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.

79 lines
2.1 KiB

  1. /*++ BUILD Version: 0001 // Increment this if a change has global effects
  2. Copyright (c) 1997-1999 Microsoft Corporation
  3. Module Name:
  4. schedule.h
  5. Abstract:
  6. This file defines a common schedule structure for use by various NT
  7. components.
  8. --*/
  9. #ifndef _SCHEDULE_H_
  10. #define _SCHEDULE_H_
  11. #if _MSC_VER > 1000
  12. #pragma once
  13. #endif
  14. #ifdef __cplusplus
  15. extern "C" {
  16. #endif
  17. //
  18. // The DS and FRS use the same structure to represent different schedules.
  19. // The DS uses a 15-minute polling schedule. FRS uses a 60-minute
  20. // start/stop schedule. Hence, the schedule for the system volume is
  21. // a special case because we only have the DS schedule to work from.
  22. // We will work around this problem by treating the 15
  23. // -minute polling schedule as a 60-minute start/stop schedule.
  24. // Replication is enabled for any hour that has any of the four
  25. // 15-minute bits set.
  26. //
  27. // When the ReplicationSchedule is not present the default is
  28. // "always replicate."
  29. //
  30. //
  31. // Only the interval schedule is currently implemented. Others are ignored.
  32. //
  33. #define SCHEDULE_INTERVAL 0 // schedule as understood by NT5
  34. #define SCHEDULE_BANDWIDTH 1 // bandwidth as understood by NT5
  35. #define SCHEDULE_PRIORITY 2 // priority as understood by NT5
  36. //
  37. // Schedule Header
  38. //
  39. // Each schedule blob begins with n array of schedule headers that
  40. // specify the number and type of schedules contained in the blob.
  41. //
  42. typedef struct _SCHEDULE_HEADER {
  43. ULONG Type; // one of the SCHEDULE_ ordinals
  44. ULONG Offset; // offset from start of schedule structure
  45. } SCHEDULE_HEADER, *PSCHEDULE_HEADER;
  46. //
  47. // Schedule
  48. //
  49. typedef struct _SCHEDULE {
  50. ULONG Size; // inclusive size in bytes
  51. ULONG Bandwidth;
  52. ULONG NumberOfSchedules;
  53. SCHEDULE_HEADER Schedules[1];
  54. } SCHEDULE, *PSCHEDULE;
  55. // The above structure is followed by the Data buffer and the
  56. // SCHEDULE_HEADER contains offsets to refer to the appropriate
  57. // parts in the data buffer.
  58. #define SCHEDULE_DATA_ENTRIES (7 * 24) // 7 days X 24 hours
  59. #ifdef __cplusplus
  60. }
  61. #endif
  62. #endif // _SCHEDULE_H_