Mercurial > hg > monetdb-java
diff src/main/java/nl/cwi/monetdb/jdbc/MonetClob.java @ 262:2d62ca1f758b
Moved utility method newSQLFeatureNotSupportedException(String name) from MonetPreparedStatement.java and MonetResultSet.java
to class MonetWrapper such that it can be called directly from all classes which extend MonetWrapper.
Call MonetWrapper.newSQLFeatureNotSupportedException() from more classes and places.
Update java documentation:
- add "@throws SQLFeatureNotSupportedException" to methods which can throw it
- remove "@throws SQLFeatureNotSupportedException" from methods which do not throw it
author | Martin van Dinther <martin.van.dinther@monetdbsolutions.com> |
---|---|
date | Thu, 03 Jan 2019 18:33:25 +0100 (2019-01-03) |
parents | d4baf8a4b43a |
children | eefa7f625673 |
line wrap: on
line diff
--- a/src/main/java/nl/cwi/monetdb/jdbc/MonetClob.java +++ b/src/main/java/nl/cwi/monetdb/jdbc/MonetClob.java @@ -15,7 +15,6 @@ import java.io.StringReader; import java.io.Writer; import java.sql.Clob; import java.sql.SQLException; -import java.sql.SQLFeatureNotSupportedException; /** * The MonetClob class implements the {@link java.sql.Clob} interface. @@ -71,7 +70,7 @@ public final class MonetClob implements */ @Override public InputStream getAsciiStream() throws SQLException { - throw new SQLFeatureNotSupportedException("Method getAsciiStream() not supported", "0A000"); + throw MonetWrapper.newSQLFeatureNotSupportedException("getAsciiStream"); } /** @@ -221,7 +220,7 @@ public final class MonetClob implements */ @Override public OutputStream setAsciiStream(long pos) throws SQLException { - throw new SQLFeatureNotSupportedException("Method setAsciiStream(long pos) not supported", "0A000"); + throw MonetWrapper.newSQLFeatureNotSupportedException("setAsciiStream"); } /** @@ -242,7 +241,7 @@ public final class MonetClob implements */ @Override public Writer setCharacterStream(long pos) throws SQLException { - throw new SQLFeatureNotSupportedException("Method setCharacterStream(long pos) not supported", "0A000"); + throw MonetWrapper.newSQLFeatureNotSupportedException("setCharacterStream"); } /**