1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44 package org.melati.poem.dbms.test.sql;
45
46 import java.io.InputStream;
47 import java.io.Reader;
48 import java.sql.Blob;
49 import java.sql.CallableStatement;
50 import java.sql.Clob;
51 import java.sql.NClob;
52 import java.sql.RowId;
53 import java.sql.SQLException;
54 import java.sql.SQLXML;
55
56
57
58
59
60
61
62
63 public abstract class ThrowingCallableStatementJdbc4
64 extends ThrowingCallableStatementJdbc3
65 implements CallableStatement {
66
67
68
69
70
71
72
73
74
75
76
77 public void setAsciiStream(int parameterIndex, InputStream x, long length)
78 throws SQLException {
79 if (shouldThrow(this.getClass().getInterfaces()[0], "setAsciiStream"))
80 throw new SQLException("CallableStatement bombed");
81 it.setAsciiStream(parameterIndex, x, length);
82 }
83
84
85
86
87
88 public void setAsciiStream(int parameterIndex, InputStream x)
89 throws SQLException {
90 if (shouldThrow(this.getClass().getInterfaces()[0], "setAsciiStream"))
91 throw new SQLException("CallableStatement bombed");
92 it.setAsciiStream(parameterIndex, x);
93 }
94
95
96
97
98
99 public void setBinaryStream(int parameterIndex, InputStream x, long length)
100 throws SQLException {
101 if (shouldThrow(this.getClass().getInterfaces()[0], "setBinaryStream"))
102 throw new SQLException("CallableStatement bombed");
103 it.setBinaryStream(parameterIndex, x, length);
104 }
105
106
107
108
109
110 public void setBinaryStream(int parameterIndex, InputStream x)
111 throws SQLException {
112 if (shouldThrow(this.getClass().getInterfaces()[0], "setBinaryStream"))
113 throw new SQLException("CallableStatement bombed");
114 it.setBinaryStream(parameterIndex, x);
115 }
116
117
118
119
120
121 public void setBlob(int parameterIndex, InputStream inputStream, long length)
122 throws SQLException {
123 if (shouldThrow(this.getClass().getInterfaces()[0], "setBlob"))
124 throw new SQLException("CallableStatement bombed");
125 it.setBlob(parameterIndex, inputStream, length);
126 }
127
128
129
130
131
132 public void setBlob(int parameterIndex, InputStream inputStream)
133 throws SQLException {
134 if (shouldThrow(this.getClass().getInterfaces()[0], "setBlob"))
135 throw new SQLException("CallableStatement bombed");
136 it.setBlob(parameterIndex, inputStream);
137 }
138
139
140
141
142
143 public void setCharacterStream(int parameterIndex, Reader reader, long length)
144 throws SQLException {
145 if (shouldThrow(this.getClass().getInterfaces()[0], "setCharacterStream"))
146 throw new SQLException("CallableStatement bombed");
147 it.setCharacterStream(parameterIndex, reader, length);
148 }
149
150
151
152
153
154 public void setCharacterStream(int parameterIndex, Reader reader)
155 throws SQLException {
156 if (shouldThrow(this.getClass().getInterfaces()[0], "setCharacterStream"))
157 throw new SQLException("CallableStatement bombed");
158 it.setCharacterStream(parameterIndex, reader);
159 }
160
161
162
163
164
165 public void setClob(int parameterIndex, Reader reader, long length)
166 throws SQLException {
167 if (shouldThrow(this.getClass().getInterfaces()[0], "setClob"))
168 throw new SQLException("CallableStatement bombed");
169 it.setClob(parameterIndex, reader, length);
170 }
171
172
173
174
175
176 public void setClob(int parameterIndex, Reader reader) throws SQLException {
177 if (shouldThrow(this.getClass().getInterfaces()[0], "setClob"))
178 throw new SQLException("CallableStatement bombed");
179 it.setClob(parameterIndex, reader);
180 }
181
182
183
184
185
186 public void setNCharacterStream(int parameterIndex, Reader value, long length)
187 throws SQLException {
188 if (shouldThrow(this.getClass().getInterfaces()[0], "setNCharacterStream"))
189 throw new SQLException("CallableStatement bombed");
190 it.setNCharacterStream(parameterIndex, value, length);
191 }
192
193
194
195
196
197 public void setNCharacterStream(int parameterIndex, Reader value)
198 throws SQLException {
199 if (shouldThrow(this.getClass().getInterfaces()[0], "setNCharacterStream"))
200 throw new SQLException("CallableStatement bombed");
201 it.setNCharacterStream(parameterIndex, value);
202 }
203
204
205
206
207
208 public void setNClob(int parameterIndex, NClob value) throws SQLException {
209 if (shouldThrow(this.getClass().getInterfaces()[0], "setNClob"))
210 throw new SQLException("CallableStatement bombed");
211 it.setNClob(parameterIndex, value);
212 }
213
214
215
216
217
218 public void setNClob(int parameterIndex, Reader reader, long length)
219 throws SQLException {
220 if (shouldThrow(this.getClass().getInterfaces()[0], "setNClob"))
221 throw new SQLException("CallableStatement bombed");
222 it.setNClob(parameterIndex, reader, length);
223 }
224
225
226
227
228
229 public void setNClob(int parameterIndex, Reader reader) throws SQLException {
230 if (shouldThrow(this.getClass().getInterfaces()[0], "setNClob"))
231 throw new SQLException("CallableStatement bombed");
232 it.setNClob(parameterIndex, reader);
233 }
234
235
236
237
238
239 public void setNString(int parameterIndex, String value) throws SQLException {
240 if (shouldThrow(this.getClass().getInterfaces()[0], "setNString"))
241 throw new SQLException("CallableStatement bombed");
242 it.setNString(parameterIndex, value);
243 }
244
245
246
247
248
249 public void setRowId(int parameterIndex, RowId x) throws SQLException {
250 if (shouldThrow(this.getClass().getInterfaces()[0], "setRowId"))
251 throw new SQLException("CallableStatement bombed");
252 it.setRowId(parameterIndex, x);
253 }
254
255
256
257
258
259 public void setSQLXML(int parameterIndex, SQLXML xmlObject)
260 throws SQLException {
261 if (shouldThrow(this.getClass().getInterfaces()[0], "setSQLXML"))
262 throw new SQLException("CallableStatement bombed");
263 it.setSQLXML(parameterIndex, xmlObject);
264 }
265
266
267
268
269
270 public boolean isClosed() throws SQLException {
271 if (shouldThrow(this.getClass().getInterfaces()[0], "isClosed"))
272 throw new SQLException("CallableStatement bombed");
273 return it.isClosed();
274 }
275
276
277
278
279
280 public boolean isPoolable() throws SQLException {
281 if (shouldThrow(this.getClass().getInterfaces()[0], "isPoolable"))
282 throw new SQLException("CallableStatement bombed");
283 return it.isPoolable();
284 }
285
286
287
288
289
290 public void setPoolable(boolean poolable) throws SQLException {
291 if (shouldThrow(this.getClass().getInterfaces()[0], "setPoolable"))
292 throw new SQLException("CallableStatement bombed");
293 it.setPoolable(poolable);
294 }
295
296
297
298
299
300 public boolean isWrapperFor(Class<?> iface) throws SQLException {
301 if (shouldThrow(this.getClass().getInterfaces()[0], "isWrapperFor"))
302 throw new SQLException("CallableStatement bombed");
303 return it.isWrapperFor(iface);
304 }
305
306
307
308
309
310 public <T> T unwrap(Class<T> iface) throws SQLException {
311 if (shouldThrow(this.getClass().getInterfaces()[0], "unwrap"))
312 throw new SQLException("CallableStatement bombed");
313 return it.unwrap(iface);
314 }
315
316
317
318
319
320 public Reader getCharacterStream(int parameterIndex) throws SQLException {
321 if (shouldThrow(this.getClass().getInterfaces()[0], "getCharacterStream"))
322 throw new SQLException("CallableStatement bombed");
323 return it.getCharacterStream(parameterIndex);
324 }
325
326
327
328
329
330 public Reader getCharacterStream(String parameterName) throws SQLException {
331 if (shouldThrow(this.getClass().getInterfaces()[0], "getCharacterStream"))
332 throw new SQLException("CallableStatement bombed");
333 return it.getCharacterStream(parameterName);
334 }
335
336
337
338
339
340 public Reader getNCharacterStream(int parameterIndex) throws SQLException {
341 if (shouldThrow(this.getClass().getInterfaces()[0], "getNCharacterStream"))
342 throw new SQLException("CallableStatement bombed");
343 return it.getNCharacterStream(parameterIndex);
344 }
345
346
347
348
349
350 public Reader getNCharacterStream(String parameterName) throws SQLException {
351 if (shouldThrow(this.getClass().getInterfaces()[0], "getNCharacterStream"))
352 throw new SQLException("CallableStatement bombed");
353 return it.getNCharacterStream(parameterName);
354 }
355
356
357
358
359
360 public NClob getNClob(int parameterIndex) throws SQLException {
361 if (shouldThrow(this.getClass().getInterfaces()[0], "getNClob"))
362 throw new SQLException("CallableStatement bombed");
363 return new ThrowingNClob(it.getNClob(parameterIndex));
364 }
365
366
367
368
369
370 public NClob getNClob(String parameterName) throws SQLException {
371 if (shouldThrow(this.getClass().getInterfaces()[0], "getNClob"))
372 throw new SQLException("CallableStatement bombed");
373 return new ThrowingNClob(it.getNClob(parameterName));
374 }
375
376
377
378
379
380 public String getNString(int parameterIndex) throws SQLException {
381 if (shouldThrow(this.getClass().getInterfaces()[0], "getNString"))
382 throw new SQLException("CallableStatement bombed");
383 return it.getNString(parameterIndex);
384 }
385
386
387
388
389
390 public String getNString(String parameterName) throws SQLException {
391 if (shouldThrow(this.getClass().getInterfaces()[0], "getNString"))
392 throw new SQLException("CallableStatement bombed");
393 return it.getNString(parameterName);
394 }
395
396
397
398
399
400 public RowId getRowId(int parameterIndex) throws SQLException {
401 if (shouldThrow(this.getClass().getInterfaces()[0], "getRowId"))
402 throw new SQLException("CallableStatement bombed");
403 return new ThrowingRowId(it.getRowId(parameterIndex));
404 }
405
406
407
408
409
410 public RowId getRowId(String parameterName) throws SQLException {
411 if (shouldThrow(this.getClass().getInterfaces()[0], "getRowId"))
412 throw new SQLException("CallableStatement bombed");
413 return new ThrowingRowId(it.getRowId(parameterName));
414 }
415
416
417
418
419
420 public SQLXML getSQLXML(int parameterIndex) throws SQLException {
421 if (shouldThrow(this.getClass().getInterfaces()[0], "getSQLXML"))
422 throw new SQLException("CallableStatement bombed");
423 return new ThrowingSQLXML(it.getSQLXML(parameterIndex));
424 }
425
426
427
428
429
430 public SQLXML getSQLXML(String parameterName) throws SQLException {
431 if (shouldThrow(this.getClass().getInterfaces()[0], "getSQLXML"))
432 throw new SQLException("CallableStatement bombed");
433 return new ThrowingSQLXML(it.getSQLXML(parameterName));
434 }
435
436
437
438
439
440 public void setAsciiStream(String parameterName, InputStream x, long length)
441 throws SQLException {
442 if (shouldThrow(this.getClass().getInterfaces()[0], "setAsciiStream"))
443 throw new SQLException("CallableStatement bombed");
444 it.setAsciiStream(parameterName, x, length);
445 }
446
447
448
449
450
451 public void setAsciiStream(String parameterName, InputStream x)
452 throws SQLException {
453 if (shouldThrow(this.getClass().getInterfaces()[0], "setAsciiStream"))
454 throw new SQLException("CallableStatement bombed");
455 it.setAsciiStream(parameterName, x);
456 }
457
458
459
460
461
462 public void setBinaryStream(String parameterName, InputStream x, long length)
463 throws SQLException {
464 if (shouldThrow(this.getClass().getInterfaces()[0], "setBinaryStream"))
465 throw new SQLException("CallableStatement bombed");
466 it.setBinaryStream(parameterName, x, length);
467 }
468
469
470
471
472
473 public void setBinaryStream(String parameterName, InputStream x)
474 throws SQLException {
475 if (shouldThrow(this.getClass().getInterfaces()[0], "setBinaryStream"))
476 throw new SQLException("CallableStatement bombed");
477 it.setBinaryStream(parameterName, x);
478 }
479
480
481
482
483
484 public void setBlob(String parameterName, Blob x) throws SQLException {
485 if (shouldThrow(this.getClass().getInterfaces()[0], "setBlob"))
486 throw new SQLException("CallableStatement bombed");
487 it.setBlob(parameterName, x);
488 }
489
490
491
492
493
494 public void setBlob(String parameterName, InputStream inputStream, long length)
495 throws SQLException {
496 if (shouldThrow(this.getClass().getInterfaces()[0], "setBlob"))
497 throw new SQLException("CallableStatement bombed");
498 it.setBlob(parameterName, inputStream, length);
499 }
500
501
502
503
504
505 public void setBlob(String parameterName, InputStream inputStream)
506 throws SQLException {
507 if (shouldThrow(this.getClass().getInterfaces()[0], "setBlob"))
508 throw new SQLException("CallableStatement bombed");
509 it.setBlob(parameterName, inputStream);
510 }
511
512
513
514
515
516 public void setCharacterStream(String parameterName, Reader reader,
517 long length) throws SQLException {
518 if (shouldThrow(this.getClass().getInterfaces()[0], "setCharacterStream"))
519 throw new SQLException("CallableStatement bombed");
520 it.setCharacterStream(parameterName, reader);
521 }
522
523
524
525
526
527 public void setCharacterStream(String parameterName, Reader reader)
528 throws SQLException {
529 if (shouldThrow(this.getClass().getInterfaces()[0], "setCharacterStream"))
530 throw new SQLException("CallableStatement bombed");
531 it.setCharacterStream(parameterName, reader);
532 }
533
534
535
536
537
538 public void setClob(String parameterName, Clob x) throws SQLException {
539 if (shouldThrow(this.getClass().getInterfaces()[0], "setClob"))
540 throw new SQLException("CallableStatement bombed");
541 it.setClob(parameterName, x);
542 }
543
544
545
546
547
548 public void setClob(String parameterName, Reader reader, long length)
549 throws SQLException {
550 if (shouldThrow(this.getClass().getInterfaces()[0], "setClob"))
551 throw new SQLException("CallableStatement bombed");
552 it.setClob(parameterName, reader, length);
553 }
554
555
556
557
558
559 public void setClob(String parameterName, Reader reader) throws SQLException {
560 if (shouldThrow(this.getClass().getInterfaces()[0], "setClob"))
561 throw new SQLException("CallableStatement bombed");
562 it.setClob(parameterName, reader);
563 }
564
565
566
567
568
569 public void setNCharacterStream(String parameterName, Reader value,
570 long length) throws SQLException {
571 if (shouldThrow(this.getClass().getInterfaces()[0], "setNCharacterStream"))
572 throw new SQLException("CallableStatement bombed");
573 it.setNCharacterStream(parameterName, value);
574 }
575
576
577
578
579
580 public void setNCharacterStream(String parameterName, Reader value)
581 throws SQLException {
582 if (shouldThrow(this.getClass().getInterfaces()[0], "setNCharacterStream"))
583 throw new SQLException("CallableStatement bombed");
584 it.setNCharacterStream(parameterName, value);
585 }
586
587
588
589
590
591 public void setNClob(String parameterName, NClob value) throws SQLException {
592 if (shouldThrow(this.getClass().getInterfaces()[0], "setNClob"))
593 throw new SQLException("CallableStatement bombed");
594 it.setNClob(parameterName, value);
595 }
596
597
598
599
600
601 public void setNClob(String parameterName, Reader reader, long length)
602 throws SQLException {
603 if (shouldThrow(this.getClass().getInterfaces()[0], "setNClob"))
604 throw new SQLException("CallableStatement bombed");
605 it.setNClob(parameterName, reader, length);
606 }
607
608
609
610
611
612 public void setNClob(String parameterName, Reader reader) throws SQLException {
613 if (shouldThrow(this.getClass().getInterfaces()[0], "setNClob"))
614 throw new SQLException("CallableStatement bombed");
615 it.setNClob(parameterName, reader);
616 }
617
618
619
620
621
622 public void setNString(String parameterName, String value)
623 throws SQLException {
624 if (shouldThrow(this.getClass().getInterfaces()[0], "setNString"))
625 throw new SQLException("CallableStatement bombed");
626 it.setNString(parameterName, value);
627 }
628
629
630
631
632
633 public void setRowId(String parameterName, RowId x) throws SQLException {
634 if (shouldThrow(this.getClass().getInterfaces()[0], "setRowId"))
635 throw new SQLException("CallableStatement bombed");
636 it.setRowId(parameterName, x);
637 }
638
639
640
641
642
643 public void setSQLXML(String parameterName, SQLXML xmlObject)
644 throws SQLException {
645 if (shouldThrow(this.getClass().getInterfaces()[0], "setSQLXML"))
646 throw new SQLException("CallableStatement bombed");
647 it.setSQLXML(parameterName, xmlObject);
648 }
649
650
651 }