2002-10-22 Tim Coleman (tim@timcoleman.com)
[mono.git] / mcs / class / Mono.Data.TdsClient / Mono.Data.TdsClient / TdsException.cs
1 //
2 // Mono.Data.TdsClient.TdsException.cs
3 //
4 // Author:
5 //   Tim Coleman (tim@timcoleman.com)
6 //
7 // Copyright (C) 2002 Tim Coleman
8 //
9
10 using Mono.Data.TdsClient.Internal;
11 using System;
12 using System.Runtime.Serialization;
13
14 namespace Mono.Data.TdsClient {
15         public class TdsException : SystemException
16         {
17                 #region Fields
18
19                 byte theClass;
20                 TdsErrorCollection errors;
21                 int lineNumber;
22                 string message;
23                 int number;
24                 string procedure;
25                 string server;
26                 string source;
27                 byte state;
28
29                 #endregion // Fields
30
31                 #region Constructors
32
33                 internal TdsException (string message)
34                 {
35                         this.message = message;
36                         errors = new TdsErrorCollection ();
37                 }
38
39                 #endregion // Constructors
40
41                 #region Properties
42
43                 public byte Class {
44                         get { return theClass; }
45                 }
46
47                 public TdsErrorCollection Errors {
48                         get { return errors; }
49                 }
50
51                 public int LineNumber {
52                         get { return lineNumber; }
53                 }
54
55                 public override string Message {
56                         get { return message; }
57                 }
58
59                 public int Number {
60                         get { return number; }
61                 }
62
63                 public string Procedure {
64                         get { return procedure; }
65                 }
66
67                 public string Server {
68                         get { return server; }
69                 }
70
71                 public override string Source {
72                         get { return source; }
73                 }
74
75                 public byte State {
76                         get { return state; }
77                 }
78
79                 #endregion // Properties
80
81                 #region Methods
82
83                 [MonoTODO]
84                 public override void GetObjectData (SerializationInfo si, StreamingContext context)
85                 {
86                         throw new NotImplementedException ();
87                 }
88
89                 #endregion // Methods
90         }
91 }