Source code: google/jdbc/driver/GoogleConnection.java
1 /**
2 * Z39.50/XML Interoperability Framework (ZiFX).
3 * Copyright (C) 2000, 2003 ZiFX Project.
4 * Francisco Queiros Pinto and Nick Ryan.
5 * ZiFX is a SourceForge Project: http://zifx.sourceforge.net/
6 *
7 * This package is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or (at your option) any later version.
11 *
12 * This package is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public
18 * License along with this package; if not, write to the Free
19 * Software Foundation, Inc., 59 Temple Place, Suite 330, Boston,
20 * MA 02111-1307 USA.
21 */
22 package google.jdbc.driver;
23
24 import java.sql.*;
25 import java.util.*;
26
27 import zava.utilities.*;
28
29 /**
30 * GoogleConnection
31 */
32 public class GoogleConnection implements Connection {
33
34
35 //The URL used to connect to the searchengine
36 protected String url = null;
37
38 GoogleConnection(String urlStr) throws SQLException {
39
40 super();
41 url = urlStr;
42 }
43
44 /**
45 *
46 */
47 public Statement createStatement() throws SQLException {
48
49 return(new GoogleStatement(url));
50 }
51
52 /**
53 *
54 */
55 public void close() throws SQLException {
56
57 Logs.writeLog("Google Connection Closed!", Logs.logDEBUG);
58 }
59
60
61 // Not Implemented
62
63
64 /**
65 *
66 */
67 public void clearWarnings() throws SQLException {
68
69 throw new MethodNotSupportedException();
70 }
71
72 /**
73 *
74 */
75 public void commit() throws SQLException {
76
77 throw new MethodNotSupportedException();
78 }
79
80 /**
81 *
82 */
83 public Statement createStatement(int resultSetType,
84 int resultSetConcurrency) throws SQLException {
85
86 throw new MethodNotSupportedException();
87 }
88
89 /**
90 *
91 */
92 public boolean getAutoCommit() throws SQLException {
93
94 throw new MethodNotSupportedException();
95 }
96
97 /**
98 *
99 */
100 public String getCatalog() throws SQLException {
101
102 throw new MethodNotSupportedException();
103 }
104
105 /**
106 *
107 */
108 public DatabaseMetaData getMetaData() throws SQLException {
109
110 throw new MethodNotSupportedException();
111 }
112
113 /**
114 *
115 */
116 public int getTransactionIsolation() throws SQLException {
117
118 throw new MethodNotSupportedException();
119 }
120
121 /**
122 *
123 */
124 public Map getTypeMap() throws SQLException {
125
126 throw new MethodNotSupportedException();
127 }
128
129 /**
130 *
131 */
132 public SQLWarning getWarnings() throws SQLException {
133
134 throw new MethodNotSupportedException();
135 }
136
137 /**
138 *
139 */
140 public boolean isClosed() throws SQLException {
141
142 throw new MethodNotSupportedException();
143 }
144
145 /**
146 *
147 */
148 public boolean isReadOnly() throws SQLException {
149
150 throw new MethodNotSupportedException();
151 }
152
153 /**
154 *
155 */
156 public String nativeSQL(String sql) throws SQLException {
157
158 throw new MethodNotSupportedException();
159 }
160
161 /**
162 *
163 */
164 public CallableStatement prepareCall(String sql) throws SQLException {
165
166 throw new MethodNotSupportedException();
167 }
168
169 /**
170 *
171 */
172 public CallableStatement prepareCall(String sql, int resultSetType,
173 int resultSetConcurrency) throws SQLException {
174
175 throw new MethodNotSupportedException();
176 }
177
178 /**
179 *
180 */
181 public PreparedStatement prepareStatement(String sql) throws SQLException {
182
183 throw new MethodNotSupportedException();
184 }
185
186 /**
187 *
188 */
189 public PreparedStatement prepareStatement(String sql, int resultSetType,
190 int resultSetConcurrency) throws SQLException {
191
192 throw new MethodNotSupportedException();
193 }
194
195 /**
196 *
197 */
198 public void rollback() throws SQLException {
199
200 throw new MethodNotSupportedException();
201 }
202
203 /**
204 *
205 */
206 public void setAutoCommit(boolean autoCommit) throws SQLException {
207
208 throw new MethodNotSupportedException();
209 }
210
211 /**
212 *
213 */
214 public void setCatalog(String catalog) throws SQLException {
215
216 throw new MethodNotSupportedException();
217 }
218
219 /**
220 *
221 */
222 public void setReadOnly(boolean readOnly) throws SQLException {
223
224 throw new MethodNotSupportedException();
225 }
226
227 /**
228 *
229 */
230 public void setTransactionIsolation(int level) throws SQLException {
231
232 throw new MethodNotSupportedException();
233 }
234
235 /**
236 *
237 */
238 public void setTypeMap(Map map) throws SQLException {
239
240 throw new MethodNotSupportedException();
241 }
242
243 /**
244 *
245 */
246 public void setHoldability(int holdability) throws SQLException {
247
248 throw new MethodNotSupportedException();
249 }
250
251 /**
252 *
253 */
254 public int getHoldability() throws SQLException {
255
256 throw new MethodNotSupportedException();
257 }
258
259 /**
260 *
261 */
262 public Savepoint setSavepoint() throws SQLException {
263
264 throw new MethodNotSupportedException();
265 }
266
267 /**
268 *
269 */
270 public Savepoint setSavepoint(String name) throws SQLException {
271
272 throw new MethodNotSupportedException();
273 }
274
275 /**
276 *
277 */
278 public void rollback(Savepoint savepoint) throws SQLException {
279
280 throw new MethodNotSupportedException();
281 }
282
283 /**
284 *
285 */
286 public void releaseSavepoint(Savepoint savepoint) throws SQLException {
287
288 throw new MethodNotSupportedException();
289 }
290
291 /**
292 *
293 */
294 public Statement createStatement(int resultSetType, int resultSetConcurrency,
295 int resultSetHoldability)
296 throws SQLException {
297
298 throw new MethodNotSupportedException();
299 }
300
301 /**
302 *
303 */
304 public PreparedStatement prepareStatement(String sql, int resultSetType,
305 int resultSetConcurrency,
306 int resultSetHoldability)
307 throws SQLException {
308
309 throw new MethodNotSupportedException();
310 }
311
312 /**
313 *
314 */
315 public CallableStatement prepareCall(String sql, int resultSetType,
316 int resultSetConcurrency,
317 int resultSetHoldability)
318 throws SQLException {
319
320 throw new MethodNotSupportedException();
321 }
322
323 /**
324 *
325 */
326 public PreparedStatement prepareStatement(String sql, int autoGeneratedKeys)
327 throws SQLException {
328
329 throw new MethodNotSupportedException();
330 }
331
332 /**
333 *
334 */
335 public PreparedStatement prepareStatement(String sql, int[] columnIndexes)
336 throws SQLException {
337
338 throw new MethodNotSupportedException();
339 }
340
341 /**
342 *
343 */
344 public PreparedStatement prepareStatement(String sql, String[] columnNames)
345 throws SQLException {
346
347 throw new MethodNotSupportedException();
348 }
349
350 }
351