Remove some deprecated libraries
[mono.git] / mcs / class / FirebirdSql.Data.Firebird / FirebirdSql.Data.Common / IscErrorCollection.cs
1 /*
2  *      Firebird ADO.NET Data provider for .NET and Mono 
3  * 
4  *         The contents of this file are subject to the Initial 
5  *         Developer's Public License Version 1.0 (the "License"); 
6  *         you may not use this file except in compliance with the 
7  *         License. You may obtain a copy of the License at 
8  *         http://www.firebirdsql.org/index.php?op=doc&id=idpl
9  *
10  *         Software distributed under the License is distributed on 
11  *         an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either 
12  *         express or implied. See the License for the specific 
13  *         language governing rights and limitations under the License.
14  * 
15  *      Copyright (c) 2002, 2005 Carlos Guzman Alvarez
16  *      All Rights Reserved.
17  */
18
19 using System;
20 using System.Collections;
21
22 namespace FirebirdSql.Data.Common
23 {
24         internal sealed class IscErrorCollection : CollectionBase
25         {
26                 #region Indexers
27
28                 public IscError this[int index]
29                 {
30                         get { return (IscError)this.List[index]; }
31                 }
32
33                 #endregion
34
35                 #region Methods
36
37                 public IscError Add(int type, string strParam)
38                 {
39                         return this.Add(new IscError(type, strParam));
40                 }
41
42                 public IscError Add(int type, int errorCode)
43                 {
44                         return this.Add(new IscError(type, errorCode));
45                 }
46
47                 public IscError Add(IscError error)
48                 {
49                         this.List.Add(error);
50
51                         return error;
52                 }
53
54                 #endregion
55         }
56 }