SqlNotificationEventArgs.cs 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. //------------------------------------------------------------------------------
  2. // <copyright file="SqlNotificationEventArgs.cs" company="Microsoft">
  3. // Copyright (c) Microsoft Corporation. All rights reserved.
  4. // </copyright>
  5. // <owner current="true" primary="true">[....]</owner>
  6. // <owner current="true" primary="false">[....]</owner>
  7. // <owner current="false" primary="true">[....]</owner>
  8. //------------------------------------------------------------------------------
  9. namespace System.Data.SqlClient {
  10. using System;
  11. using System.ComponentModel;
  12. using System.Collections;
  13. using System.Data;
  14. public class SqlNotificationEventArgs : EventArgs {
  15. private SqlNotificationType _type;
  16. private SqlNotificationInfo _info;
  17. private SqlNotificationSource _source;
  18. public SqlNotificationEventArgs(SqlNotificationType type, SqlNotificationInfo info, SqlNotificationSource source) {
  19. _info = info;
  20. _source = source;
  21. _type = type;
  22. }
  23. public SqlNotificationType Type {
  24. get {
  25. return _type;
  26. }
  27. }
  28. public SqlNotificationInfo Info {
  29. get {
  30. return _info;
  31. }
  32. }
  33. public SqlNotificationSource Source {
  34. get {
  35. return _source;
  36. }
  37. }
  38. internal static SqlNotificationEventArgs NotifyError = new SqlNotificationEventArgs(SqlNotificationType.Subscribe, SqlNotificationInfo.Error, SqlNotificationSource.Object);
  39. }
  40. }