Leaked source code of windows server 2003
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.

72 lines
2.0 KiB

  1. /*
  2. * NOTES:
  3. *
  4. * REVISIONS:
  5. * jod30Nov92: Added GCIP object stuff
  6. * jod02Dec92: Fixed Jim's sloppy code
  7. * jod13Jan93: Added eventList to InterpretMessage
  8. * pcy21Apr93: OS2 FE merge
  9. * pcy21May93: PROTOSIZE changed from 2600 to 8000
  10. * cad22Jul93: Fixed up destructor conflicts and omissions
  11. * pcy17Aug93: Removing strtok() requires new arg in InterpretParameters
  12. * cad28Sep93: Made sure destructor(s) virtual
  13. * cad07Oct93: Made methods virtual
  14. * djs22Feb96: Added ChangeSet method
  15. * cgm04May96: TestResponse now uses BufferSize
  16. */
  17. #ifndef __PROTSMRT_H
  18. #define __PROTSMRT_H
  19. #include "_defs.h"
  20. #include "apc.h"
  21. //
  22. // Defines
  23. //
  24. _CLASSDEF(UpsLinkProtocol)
  25. //
  26. // Implementation uses
  27. //
  28. #include "protsimp.h"
  29. #include "err.h"
  30. #include "trans.h"
  31. //
  32. // Interface uses
  33. //
  34. _CLASSDEF(List)
  35. _CLASSDEF(Message)
  36. class UpsLinkProtocol : public SimpleUpsProtocol
  37. {
  38. private:
  39. PCHAR FindCRLF(PCHAR InBuffer);
  40. protected:
  41. virtual VOID EventSearch(PCHAR Buffer, PList eventlist);
  42. virtual VOID SetupMessage(PMessage msg);
  43. virtual INT InterpretSetMessage(PMessage msg, PList newmsglist);
  44. public:
  45. UpsLinkProtocol();
  46. VOID InitProtocol();
  47. virtual INT BuildPollTransactionGroupMessages(PTransactionGroup
  48. aTransactionGroup);
  49. virtual INT BuildMessage(PMessage msg, PList msglist=(PList)NULL);
  50. virtual INT InterpretMessage(PMessage msg, PList eventList,
  51. PList newmsglist=(PList)NULL);
  52. virtual INT TestResponse(PMessage msg,PCHAR Buffer,USHORT BufferSize);
  53. virtual PList BuildTransactionMessageList(Type aType, INT aCode,
  54. PCHAR aValue);
  55. virtual PList BuildDataSetMessage(INT aCode, PCHAR aValue);
  56. virtual PList BuildDecrementSetMessage(INT aCode, PCHAR aValue);
  57. virtual PList BuildPauseSetMessage(INT aCode, PCHAR aValue);
  58. virtual PList BuildChangeSetMessage(INT aCode, PCHAR aValue);
  59. virtual INT BuildPollMessage(PMessage msg, PList msglist=(PList)NULL);
  60. };
  61. #endif