IForecourtControlEvents.cs 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. #region --------------- Copyright Dresser Wayne Pignone -------------
  2. /*
  3. * $Log: /Wrk/Support/ForecourtControl/Wrk/ForecourtControl/Com/IForecourtControlEvents.cs $
  4. *
  5. * 5 07-10-22 11:19 roger.månsson
  6. * Added OnFuelPriceChange event.
  7. *
  8. * 4 07-03-09 15:33 roger.månsson
  9. * Removed DispId definitions. The automatically generated works just
  10. * fine.
  11. *
  12. * 3 07-02-16 9:59 roger.månsson
  13. * FxCop changes
  14. *
  15. * 2 07-01-05 9:01 roger.månsson
  16. * Documentation changes
  17. */
  18. #endregion
  19. using System.Runtime.InteropServices;
  20. namespace Wayne.ForecourtControl.Com
  21. {
  22. /// <summary>
  23. /// Event interface for the IForecourtControl. Contains the event sink interface for the forecourt
  24. /// control object.
  25. /// </summary>
  26. [ComVisible(true)]
  27. [InterfaceType(ComInterfaceType.InterfaceIsIDispatch)]
  28. public interface IForecourtControlEvents
  29. {
  30. #region Response events
  31. /// <summary>
  32. /// Event that will be invoked when a call to SetSiteOpenendAsync has completed.
  33. /// </summary>
  34. /// <param name="sender">Sender object</param>
  35. /// <param name="success">True if the operation succeeded</param>
  36. /// <param name="userToken">The user token that was specified in the request.</param>
  37. void OnSetSiteOpenedCompleted(IForecourtControl sender, bool success, object userToken);
  38. /// <summary>
  39. /// Event that will be invoked when a call to SetSiteModeAsync has completed.
  40. /// </summary>
  41. /// <param name="sender">Sender object</param>
  42. /// <param name="success">True if the operation succeeded</param>
  43. /// <param name="userToken">The user token that was specified in the request.</param>
  44. void OnSetSiteModeCompleted(IForecourtControl sender, bool success, object userToken);
  45. /// <summary>
  46. /// Event that will be invoked when a call to ReserveFuelPricesAsync has completed.
  47. /// </summary>
  48. /// <param name="sender">Sender object</param>
  49. /// <param name="success">True if the operation succeeded</param>
  50. /// <param name="userToken">The user token that was specified in the request.</param>
  51. void OnReserveFuelPricesCompleted(IForecourtControl sender, bool success, object userToken);
  52. /// <summary>
  53. /// Event that will be invoked when a call to UnreserveFuelPricesAsync has completed.
  54. /// </summary>
  55. /// <param name="sender">Sender object</param>
  56. /// <param name="success">True if the operation succeeded</param>
  57. /// <param name="userToken">The user token that was specified in the request.</param>
  58. void OnUnreserveFuelPricesCompleted(IForecourtControl sender, bool success, object userToken);
  59. /// <summary>
  60. /// Event that will be invoked when a call to ActivateFuelPricesAsync has completed.
  61. /// </summary>
  62. /// <param name="sender">Sender object</param>
  63. /// <param name="success">True if the operation succeeded</param>
  64. /// <param name="userToken">The user token that was specified in the request.</param>
  65. void OnActivateFuelPricesCompleted(IForecourtControl sender, bool success, object userToken);
  66. #endregion
  67. #region Unsolicited events
  68. /// <summary>
  69. /// Site mode has changed. Either the site mode or the site open/closed status has changed.
  70. /// </summary>
  71. /// <param name="sender"></param>
  72. /// <param name="siteMode"></param>
  73. /// <param name="siteOpen"></param>
  74. [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1702:CompoundWordsShouldBeCasedCorrectly", MessageId = "OnSite")]
  75. void OnSiteModeChange(IForecourtControl sender, int siteMode, bool siteOpen);
  76. /// <summary>
  77. /// Connection state to the Forecourt Control has changed.
  78. /// </summary>
  79. /// <param name="sender"></param>
  80. /// <param name="connectionState"></param>
  81. void OnConnectionStateChange(IForecourtControl sender, DeviceConnectionState connectionState);
  82. /// <summary>
  83. ///
  84. /// </summary>
  85. /// <param name="sender"></param>
  86. /// <param name="e"></param>
  87. [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1704:IdentifiersShouldBeSpelledCorrectly", MessageId = "1#e")]
  88. void OnAlarm(IForecourtControl sender, IAlarmEventArgs e);
  89. /// <summary>
  90. /// Event fired when the fuel prices has been changed on the station and a new fuel price shift has been
  91. /// created.
  92. /// </summary>
  93. /// <param name="sender"></param>
  94. /// <param name="fuelPeriodId">The new Fuel period id.</param>
  95. void OnFuelPriceChange(IForecourtControl sender, int fuelPeriodId);
  96. #endregion
  97. }
  98. }