a48d5d7415f93e1d4a416c395ac7d0976b387a72
[mono.git] / mcs / class / referencesource / System.Data / System / Data / Odbc / OdbcConnectionPoolProviderInfo.cs
1 //------------------------------------------------------------------------------
2 // <copyright file="OdbcConnectionPoolProviderInfo.cs" company="Microsoft">
3 //     Copyright (c) Microsoft Corporation.  All rights reserved.
4 // </copyright>
5 // <owner current="true" primary="true">Microsoft</owner>
6 // <owner current="true" primary="false">Microsoft</owner>
7 //------------------------------------------------------------------------------
8
9 namespace System.Data.Odbc
10 {
11     using System;
12     using System.Data;
13     using System.Data.ProviderBase;
14
15     sealed internal class OdbcConnectionPoolGroupProviderInfo : DbConnectionPoolGroupProviderInfo {
16         private string  _driverName;
17         private string  _driverVersion;
18         private string  _quoteChar;
19         
20         private char    _escapeChar;
21         private bool    _hasQuoteChar;
22         private bool    _hasEscapeChar;
23
24         private bool    _isV3Driver;
25         private int     _supportedSQLTypes;
26         private int     _testedSQLTypes;
27         private int     _restrictedSQLBindTypes;   // These, otherwise supported types, are not available for binding
28
29         // flags for unsupported Attributes
30         private bool    _noCurrentCatalog;
31         private bool    _noConnectionDead;
32
33         private bool    _noQueryTimeout;
34         private bool    _noSqlSoptSSNoBrowseTable;
35         private bool    _noSqlSoptSSHiddenColumns;
36
37         // SSS_WARNINGS_OFF
38         private bool    _noSqlCASSColumnKey;
39         // SSS_WARNINGS_ON
40         
41         // flags for unsupported Functions
42         private bool   _noSqlPrimaryKeys;
43
44         internal string DriverName {
45             get {
46                 return _driverName;
47             }
48             set {
49                 _driverName = value;
50             }
51         }
52
53         internal string DriverVersion {
54             get {
55                 return _driverVersion;
56             }
57             set {
58                 _driverVersion = value;
59             }
60         }
61
62         internal bool HasQuoteChar {
63             // the value is set together with the QuoteChar (see set_QuoteChar);
64             get {
65                 return _hasQuoteChar;
66             }
67         }
68
69         internal bool HasEscapeChar {
70             // the value is set together with the EscapeChar (see set_EscapeChar);
71             get {
72                 return _hasEscapeChar;
73             }
74         }
75
76
77         internal string QuoteChar {
78             get {
79                 return _quoteChar;
80             }
81             set {
82                 _quoteChar = value;
83                 _hasQuoteChar = true;
84             }
85         }
86
87         internal char EscapeChar {
88             get {
89                 return _escapeChar;
90             }
91             set {
92                 _escapeChar = value;
93                 _hasEscapeChar = true;
94             }
95         }
96
97         internal bool IsV3Driver {
98             get {
99                 return _isV3Driver;
100             }
101             set {
102                 _isV3Driver = value;
103             }
104         }
105
106         internal int SupportedSQLTypes {
107             get {
108                 return _supportedSQLTypes;
109             }
110             set {
111                 _supportedSQLTypes = value;
112             }
113         }
114
115         internal int TestedSQLTypes {
116             get {
117                 return _testedSQLTypes;
118             }
119             set {
120                 _testedSQLTypes = value;
121             }
122         }
123
124         internal int RestrictedSQLBindTypes {
125             get {
126                 return _restrictedSQLBindTypes;
127             }
128             set {
129                 _restrictedSQLBindTypes = value;
130             }
131         }
132
133
134         internal bool NoCurrentCatalog {
135             get {
136                 return _noCurrentCatalog;
137             }
138             set {
139                 _noCurrentCatalog = value;
140             }
141         }
142
143         internal bool NoConnectionDead {
144             get {
145                 return _noConnectionDead;
146             }
147             set {
148                 _noConnectionDead = value;
149             }
150         }
151
152
153         internal bool NoQueryTimeout {
154             get {
155                 return _noQueryTimeout;
156             }
157             set {
158                 _noQueryTimeout = value;
159             }
160         }
161
162         internal bool NoSqlSoptSSNoBrowseTable {
163             get {
164                 return _noSqlSoptSSNoBrowseTable;
165             }
166             set {
167                 _noSqlSoptSSNoBrowseTable = value;
168             }
169         }
170
171         internal bool NoSqlSoptSSHiddenColumns {
172             get {
173                 return _noSqlSoptSSHiddenColumns;
174             }
175             set {
176                 _noSqlSoptSSHiddenColumns = value;
177             }
178         }
179
180         // SSS_WARNINGS_OFF
181         internal bool NoSqlCASSColumnKey {
182             get {
183                 return _noSqlCASSColumnKey;
184             }
185             set {
186                 _noSqlCASSColumnKey = value;
187             }
188         }
189         // SSS_WARNINGS_ON
190
191         internal bool NoSqlPrimaryKeys {
192             get {
193                 return _noSqlPrimaryKeys;
194             }
195             set {
196                 _noSqlPrimaryKeys = value;
197             }
198         }
199     }
200 }
201
202