View Javadoc
1   /*
2    * Licensed to the Apache Software Foundation (ASF) under one or more
3    * contributor license agreements.  See the NOTICE file distributed with
4    * this work for additional information regarding copyright ownership.
5    * The ASF licenses this file to You under the Apache License, Version 2.0
6    * (the "License"); you may not use this file except in compliance with
7    * the License.  You may obtain a copy of the License at
8    *
9    *     http://www.apache.org/licenses/LICENSE-2.0
10   *
11   * Unless required by applicable law or agreed to in writing, software
12   * distributed under the License is distributed on an "AS IS" BASIS,
13   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   * See the License for the specific language governing permissions and
15   * limitations under the License.
16   */
17  
18  package org.apache.shardingsphere.driver.jdbc.unsupported;
19  
20  import org.apache.shardingsphere.driver.jdbc.adapter.WrapperAdapter;
21  
22  import java.io.InputStream;
23  import java.io.Reader;
24  import java.math.BigDecimal;
25  import java.sql.Array;
26  import java.sql.Blob;
27  import java.sql.Clob;
28  import java.sql.Date;
29  import java.sql.NClob;
30  import java.sql.Ref;
31  import java.sql.ResultSet;
32  import java.sql.RowId;
33  import java.sql.SQLException;
34  import java.sql.SQLFeatureNotSupportedException;
35  import java.sql.SQLXML;
36  import java.sql.Time;
37  import java.sql.Timestamp;
38  
39  /**
40   * Unsupported {@code ResultSet} methods.
41   */
42  public abstract class AbstractUnsupportedUpdateOperationResultSet extends WrapperAdapter implements ResultSet {
43      
44      @Override
45      public final void updateNull(final int columnIndex) throws SQLException {
46          throw new SQLFeatureNotSupportedException("updateXXX");
47      }
48      
49      @Override
50      public final void updateNull(final String columnLabel) throws SQLException {
51          throw new SQLFeatureNotSupportedException("updateXXX");
52      }
53      
54      @Override
55      public final void updateBoolean(final int columnIndex, final boolean x) throws SQLException {
56          throw new SQLFeatureNotSupportedException("updateXXX");
57      }
58      
59      @Override
60      public final void updateBoolean(final String columnLabel, final boolean x) throws SQLException {
61          throw new SQLFeatureNotSupportedException("updateXXX");
62      }
63      
64      @Override
65      public final void updateByte(final int columnIndex, final byte x) throws SQLException {
66          throw new SQLFeatureNotSupportedException("updateXXX");
67      }
68      
69      @Override
70      public final void updateByte(final String columnLabel, final byte x) throws SQLException {
71          throw new SQLFeatureNotSupportedException("updateXXX");
72      }
73      
74      @Override
75      public final void updateShort(final int columnIndex, final short x) throws SQLException {
76          throw new SQLFeatureNotSupportedException("updateXXX");
77      }
78      
79      @Override
80      public final void updateShort(final String columnLabel, final short x) throws SQLException {
81          throw new SQLFeatureNotSupportedException("updateXXX");
82      }
83      
84      @Override
85      public final void updateInt(final int columnIndex, final int x) throws SQLException {
86          throw new SQLFeatureNotSupportedException("updateXXX");
87      }
88      
89      @Override
90      public final void updateInt(final String columnLabel, final int x) throws SQLException {
91          throw new SQLFeatureNotSupportedException("updateXXX");
92      }
93      
94      @Override
95      public final void updateLong(final int columnIndex, final long x) throws SQLException {
96          throw new SQLFeatureNotSupportedException("updateXXX");
97      }
98      
99      @Override
100     public final void updateLong(final String columnLabel, final long x) throws SQLException {
101         throw new SQLFeatureNotSupportedException("updateXXX");
102     }
103     
104     @Override
105     public final void updateFloat(final int columnIndex, final float x) throws SQLException {
106         throw new SQLFeatureNotSupportedException("updateXXX");
107     }
108     
109     @Override
110     public final void updateFloat(final String columnLabel, final float x) throws SQLException {
111         throw new SQLFeatureNotSupportedException("updateXXX");
112     }
113     
114     @Override
115     public final void updateDouble(final int columnIndex, final double x) throws SQLException {
116         throw new SQLFeatureNotSupportedException("updateXXX");
117     }
118     
119     @Override
120     public final void updateDouble(final String columnLabel, final double x) throws SQLException {
121         throw new SQLFeatureNotSupportedException("updateXXX");
122     }
123     
124     @Override
125     public final void updateBigDecimal(final int columnIndex, final BigDecimal x) throws SQLException {
126         throw new SQLFeatureNotSupportedException("updateXXX");
127     }
128     
129     @Override
130     public final void updateBigDecimal(final String columnLabel, final BigDecimal x) throws SQLException {
131         throw new SQLFeatureNotSupportedException("updateXXX");
132     }
133     
134     @Override
135     public final void updateString(final int columnIndex, final String x) throws SQLException {
136         throw new SQLFeatureNotSupportedException("updateXXX");
137     }
138     
139     @Override
140     public final void updateString(final String columnLabel, final String x) throws SQLException {
141         throw new SQLFeatureNotSupportedException("updateXXX");
142     }
143     
144     @Override
145     public final void updateNString(final int columnIndex, final String nString) throws SQLException {
146         throw new SQLFeatureNotSupportedException("updateXXX");
147     }
148     
149     @Override
150     public final void updateNString(final String columnLabel, final String nString) throws SQLException {
151         throw new SQLFeatureNotSupportedException("updateXXX");
152     }
153     
154     @Override
155     public final void updateBytes(final int columnIndex, final byte[] x) throws SQLException {
156         throw new SQLFeatureNotSupportedException("updateXXX");
157     }
158     
159     @Override
160     public final void updateBytes(final String columnLabel, final byte[] x) throws SQLException {
161         throw new SQLFeatureNotSupportedException("updateXXX");
162     }
163     
164     @Override
165     public final void updateDate(final int columnIndex, final Date x) throws SQLException {
166         throw new SQLFeatureNotSupportedException("updateXXX");
167     }
168     
169     @Override
170     public final void updateDate(final String columnLabel, final Date x) throws SQLException {
171         throw new SQLFeatureNotSupportedException("updateXXX");
172     }
173     
174     @Override
175     public final void updateTime(final int columnIndex, final Time x) throws SQLException {
176         throw new SQLFeatureNotSupportedException("updateXXX");
177     }
178     
179     @Override
180     public final void updateTime(final String columnLabel, final Time x) throws SQLException {
181         throw new SQLFeatureNotSupportedException("updateXXX");
182     }
183     
184     @Override
185     public final void updateTimestamp(final int columnIndex, final Timestamp x) throws SQLException {
186         throw new SQLFeatureNotSupportedException("updateXXX");
187     }
188     
189     @Override
190     public final void updateTimestamp(final String columnLabel, final Timestamp x) throws SQLException {
191         throw new SQLFeatureNotSupportedException("updateXXX");
192     }
193     
194     @Override
195     public final void updateAsciiStream(final int columnIndex, final InputStream inputStream) throws SQLException {
196         throw new SQLFeatureNotSupportedException("updateXXX");
197     }
198     
199     @Override
200     public final void updateAsciiStream(final String columnLabel, final InputStream inputStream) throws SQLException {
201         throw new SQLFeatureNotSupportedException("updateXXX");
202     }
203     
204     @Override
205     public final void updateAsciiStream(final int columnIndex, final InputStream x, final int length) throws SQLException {
206         throw new SQLFeatureNotSupportedException("updateXXX");
207     }
208     
209     @Override
210     public final void updateAsciiStream(final String columnLabel, final InputStream x, final int length) throws SQLException {
211         throw new SQLFeatureNotSupportedException("updateXXX");
212     }
213     
214     @Override
215     public final void updateAsciiStream(final int columnIndex, final InputStream inputStream, final long length) throws SQLException {
216         throw new SQLFeatureNotSupportedException("updateXXX");
217     }
218     
219     @Override
220     public final void updateAsciiStream(final String columnLabel, final InputStream inputStream, final long length) throws SQLException {
221         throw new SQLFeatureNotSupportedException("updateXXX");
222     }
223     
224     @Override
225     public final void updateBinaryStream(final int columnIndex, final InputStream x) throws SQLException {
226         throw new SQLFeatureNotSupportedException("updateXXX");
227     }
228     
229     @Override
230     public final void updateBinaryStream(final String columnLabel, final InputStream x) throws SQLException {
231         throw new SQLFeatureNotSupportedException("updateXXX");
232     }
233     
234     @Override
235     public final void updateBinaryStream(final int columnIndex, final InputStream x, final int length) throws SQLException {
236         throw new SQLFeatureNotSupportedException("updateXXX");
237     }
238     
239     @Override
240     public final void updateBinaryStream(final String columnLabel, final InputStream x, final int length) throws SQLException {
241         throw new SQLFeatureNotSupportedException("updateXXX");
242     }
243     
244     @Override
245     public final void updateBinaryStream(final int columnIndex, final InputStream x, final long length) throws SQLException {
246         throw new SQLFeatureNotSupportedException("updateXXX");
247     }
248     
249     @Override
250     public final void updateBinaryStream(final String columnLabel, final InputStream x, final long length) throws SQLException {
251         throw new SQLFeatureNotSupportedException("updateXXX");
252     }
253     
254     @Override
255     public final void updateCharacterStream(final int columnIndex, final Reader x) throws SQLException {
256         throw new SQLFeatureNotSupportedException("updateXXX");
257     }
258     
259     @Override
260     public final void updateCharacterStream(final String columnLabel, final Reader x) throws SQLException {
261         throw new SQLFeatureNotSupportedException("updateXXX");
262     }
263     
264     @Override
265     public final void updateCharacterStream(final int columnIndex, final Reader x, final int length) throws SQLException {
266         throw new SQLFeatureNotSupportedException("updateXXX");
267     }
268     
269     @Override
270     public final void updateCharacterStream(final String columnLabel, final Reader reader, final int length) throws SQLException {
271         throw new SQLFeatureNotSupportedException("updateXXX");
272     }
273     
274     @Override
275     public final void updateCharacterStream(final int columnIndex, final Reader x, final long length) throws SQLException {
276         throw new SQLFeatureNotSupportedException("updateXXX");
277     }
278     
279     @Override
280     public final void updateCharacterStream(final String columnLabel, final Reader reader, final long length) throws SQLException {
281         throw new SQLFeatureNotSupportedException("updateXXX");
282     }
283     
284     @Override
285     public final void updateNCharacterStream(final int columnIndex, final Reader x) throws SQLException {
286         throw new SQLFeatureNotSupportedException("updateXXX");
287     }
288     
289     @Override
290     public final void updateNCharacterStream(final String columnLabel, final Reader x) throws SQLException {
291         throw new SQLFeatureNotSupportedException("updateXXX");
292     }
293     
294     @Override
295     public final void updateNCharacterStream(final int columnIndex, final Reader x, final long length) throws SQLException {
296         throw new SQLFeatureNotSupportedException("updateXXX");
297     }
298     
299     @Override
300     public final void updateNCharacterStream(final String columnLabel, final Reader x, final long length) throws SQLException {
301         throw new SQLFeatureNotSupportedException("updateXXX");
302     }
303     
304     @Override
305     public final void updateObject(final int columnIndex, final Object x) throws SQLException {
306         throw new SQLFeatureNotSupportedException("updateXXX");
307     }
308     
309     @Override
310     public final void updateObject(final String columnLabel, final Object x) throws SQLException {
311         throw new SQLFeatureNotSupportedException("updateXXX");
312     }
313     
314     @Override
315     public final void updateObject(final int columnIndex, final Object x, final int scaleOrLength) throws SQLException {
316         throw new SQLFeatureNotSupportedException("updateXXX");
317     }
318     
319     @Override
320     public final void updateObject(final String columnLabel, final Object x, final int scaleOrLength) throws SQLException {
321         throw new SQLFeatureNotSupportedException("updateXXX");
322     }
323     
324     @Override
325     public final void updateRef(final int columnIndex, final Ref x) throws SQLException {
326         throw new SQLFeatureNotSupportedException("updateXXX");
327     }
328     
329     @Override
330     public final void updateRef(final String columnLabel, final Ref x) throws SQLException {
331         throw new SQLFeatureNotSupportedException("updateXXX");
332     }
333     
334     @Override
335     public final void updateBlob(final int columnIndex, final Blob x) throws SQLException {
336         throw new SQLFeatureNotSupportedException("updateXXX");
337     }
338     
339     @Override
340     public final void updateBlob(final String columnLabel, final Blob x) throws SQLException {
341         throw new SQLFeatureNotSupportedException("updateXXX");
342     }
343     
344     @Override
345     public final void updateBlob(final int columnIndex, final InputStream inputStream) throws SQLException {
346         throw new SQLFeatureNotSupportedException("updateXXX");
347     }
348     
349     @Override
350     public final void updateBlob(final String columnLabel, final InputStream inputStream) throws SQLException {
351         throw new SQLFeatureNotSupportedException("updateXXX");
352     }
353     
354     @Override
355     public final void updateBlob(final int columnIndex, final InputStream inputStream, final long length) throws SQLException {
356         throw new SQLFeatureNotSupportedException("updateXXX");
357     }
358     
359     @Override
360     public final void updateBlob(final String columnLabel, final InputStream inputStream, final long length) throws SQLException {
361         throw new SQLFeatureNotSupportedException("updateXXX");
362     }
363     
364     @Override
365     public final void updateClob(final int columnIndex, final Clob x) throws SQLException {
366         throw new SQLFeatureNotSupportedException("updateXXX");
367     }
368     
369     @Override
370     public final void updateClob(final String columnLabel, final Clob x) throws SQLException {
371         throw new SQLFeatureNotSupportedException("updateXXX");
372     }
373     
374     @Override
375     public final void updateClob(final int columnIndex, final Reader reader) throws SQLException {
376         throw new SQLFeatureNotSupportedException("updateXXX");
377     }
378     
379     @Override
380     public final void updateClob(final String columnLabel, final Reader reader) throws SQLException {
381         throw new SQLFeatureNotSupportedException("updateXXX");
382     }
383     
384     @Override
385     public final void updateClob(final int columnIndex, final Reader reader, final long length) throws SQLException {
386         throw new SQLFeatureNotSupportedException("updateXXX");
387     }
388     
389     @Override
390     public final void updateClob(final String columnLabel, final Reader reader, final long length) throws SQLException {
391         throw new SQLFeatureNotSupportedException("updateXXX");
392     }
393     
394     @Override
395     public final void updateNClob(final int columnIndex, final NClob nClob) throws SQLException {
396         throw new SQLFeatureNotSupportedException("updateXXX");
397     }
398     
399     @Override
400     public final void updateNClob(final String columnLabel, final NClob nClob) throws SQLException {
401         throw new SQLFeatureNotSupportedException("updateXXX");
402     }
403     
404     @Override
405     public final void updateNClob(final int columnIndex, final Reader reader) throws SQLException {
406         throw new SQLFeatureNotSupportedException("updateXXX");
407     }
408     
409     @Override
410     public final void updateNClob(final String columnLabel, final Reader reader) throws SQLException {
411         throw new SQLFeatureNotSupportedException("updateXXX");
412     }
413     
414     @Override
415     public final void updateNClob(final int columnIndex, final Reader reader, final long length) throws SQLException {
416         throw new SQLFeatureNotSupportedException("updateXXX");
417     }
418     
419     @Override
420     public final void updateNClob(final String columnLabel, final Reader reader, final long length) throws SQLException {
421         throw new SQLFeatureNotSupportedException("updateXXX");
422     }
423     
424     @Override
425     public final void updateArray(final int columnIndex, final Array x) throws SQLException {
426         throw new SQLFeatureNotSupportedException("updateXXX");
427     }
428     
429     @Override
430     public final void updateArray(final String columnLabel, final Array x) throws SQLException {
431         throw new SQLFeatureNotSupportedException("updateXXX");
432     }
433     
434     @Override
435     public final void updateRowId(final int columnIndex, final RowId x) throws SQLException {
436         throw new SQLFeatureNotSupportedException("updateXXX");
437     }
438     
439     @Override
440     public final void updateRowId(final String columnLabel, final RowId x) throws SQLException {
441         throw new SQLFeatureNotSupportedException("updateXXX");
442     }
443     
444     @Override
445     public final void updateSQLXML(final int columnIndex, final SQLXML xmlObject) throws SQLException {
446         throw new SQLFeatureNotSupportedException("updateXXX");
447     }
448     
449     @Override
450     public final void updateSQLXML(final String columnLabel, final SQLXML xmlObject) throws SQLException {
451         throw new SQLFeatureNotSupportedException("updateXXX");
452     }
453 }