OleDbError.cs 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. //
  2. // System.Data.OleDb.OleDbError
  3. //
  4. // Authors:
  5. // Rodrigo Moya ([email protected])
  6. // Tim Coleman ([email protected])
  7. //
  8. // Copyright (C) Rodrigo Moya, 2002
  9. // Copyright (C) Tim Coleman, 2002
  10. //
  11. using System.Data;
  12. using System.Data.Common;
  13. namespace System.Data.OleDb
  14. {
  15. public sealed class OleDbError
  16. {
  17. private string errorMessage;
  18. private int nativeError;
  19. private string errorSource;
  20. private string sqlState;
  21. #region Constructors
  22. internal OleDbError (string msg, int code, string source, string sql)
  23. {
  24. errorMessage = msg;
  25. nativeError = code;
  26. errorSource = source;
  27. sqlState = sql;
  28. }
  29. #endregion // Constructors
  30. #region Properties
  31. public string Message {
  32. get {
  33. return errorMessage;
  34. }
  35. }
  36. public int NativeError {
  37. get {
  38. return nativeError;
  39. }
  40. }
  41. public string Source {
  42. get {
  43. return errorSource;
  44. }
  45. }
  46. public string SqlState {
  47. get {
  48. return sqlState;
  49. }
  50. }
  51. #endregion
  52. #region Methods
  53. [MonoTODO]
  54. public override string ToString ()
  55. {
  56. throw new NotImplementedException ();
  57. }
  58. #endregion
  59. }
  60. }