You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2016/05/13 16:35:34 UTC
svn commit: r1743697 [2/8] - in /tomcat/trunk:
java/org/apache/tomcat/dbcp/dbcp2/
java/org/apache/tomcat/dbcp/dbcp2/cpdsadapter/
java/org/apache/tomcat/dbcp/dbcp2/datasources/ webapps/docs/
Modified: tomcat/trunk/java/org/apache/tomcat/dbcp/dbcp2/DelegatingCallableStatement.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/dbcp/dbcp2/DelegatingCallableStatement.java?rev=1743697&r1=1743696&r2=1743697&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/dbcp/dbcp2/DelegatingCallableStatement.java (original)
+++ tomcat/trunk/java/org/apache/tomcat/dbcp/dbcp2/DelegatingCallableStatement.java Fri May 13 16:35:33 2016
@@ -64,715 +64,715 @@ public class DelegatingCallableStatement
* @param c the {@link DelegatingConnection} that created this statement
* @param s the {@link CallableStatement} to delegate all calls to
*/
- public DelegatingCallableStatement(DelegatingConnection<?> c,
- CallableStatement s) {
+ public DelegatingCallableStatement(final DelegatingConnection<?> c,
+ final CallableStatement s) {
super(c, s);
}
@Override
- public void registerOutParameter(int parameterIndex, int sqlType) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter( parameterIndex, sqlType); } catch (SQLException e) { handleException(e); } }
+ public void registerOutParameter(final int parameterIndex, final int sqlType) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter( parameterIndex, sqlType); } catch (final SQLException e) { handleException(e); } }
@Override
- public void registerOutParameter(int parameterIndex, int sqlType, int scale) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter( parameterIndex, sqlType, scale); } catch (SQLException e) { handleException(e); } }
+ public void registerOutParameter(final int parameterIndex, final int sqlType, final int scale) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter( parameterIndex, sqlType, scale); } catch (final SQLException e) { handleException(e); } }
@Override
public boolean wasNull() throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).wasNull(); } catch (SQLException e) { handleException(e); return false; } }
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).wasNull(); } catch (final SQLException e) { handleException(e); return false; } }
@Override
- public String getString(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getString( parameterIndex); } catch (SQLException e) { handleException(e); return null; } }
+ public String getString(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getString( parameterIndex); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public boolean getBoolean(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBoolean( parameterIndex); } catch (SQLException e) { handleException(e); return false; } }
+ public boolean getBoolean(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBoolean( parameterIndex); } catch (final SQLException e) { handleException(e); return false; } }
@Override
- public byte getByte(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getByte( parameterIndex); } catch (SQLException e) { handleException(e); return 0; } }
+ public byte getByte(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getByte( parameterIndex); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public short getShort(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getShort( parameterIndex); } catch (SQLException e) { handleException(e); return 0; } }
+ public short getShort(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getShort( parameterIndex); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public int getInt(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getInt( parameterIndex); } catch (SQLException e) { handleException(e); return 0; } }
+ public int getInt(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getInt( parameterIndex); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public long getLong(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getLong( parameterIndex); } catch (SQLException e) { handleException(e); return 0; } }
+ public long getLong(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getLong( parameterIndex); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public float getFloat(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getFloat( parameterIndex); } catch (SQLException e) { handleException(e); return 0; } }
+ public float getFloat(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getFloat( parameterIndex); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public double getDouble(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getDouble( parameterIndex); } catch (SQLException e) { handleException(e); return 0; } }
+ public double getDouble(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getDouble( parameterIndex); } catch (final SQLException e) { handleException(e); return 0; } }
/** @deprecated Use {@link #getBigDecimal(int)} or {@link #getBigDecimal(String)} */
@Override
@Deprecated
- public BigDecimal getBigDecimal(int parameterIndex, int scale) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBigDecimal( parameterIndex, scale); } catch (SQLException e) { handleException(e); return null; } }
+ public BigDecimal getBigDecimal(final int parameterIndex, final int scale) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBigDecimal( parameterIndex, scale); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public byte[] getBytes(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBytes( parameterIndex); } catch (SQLException e) { handleException(e); return null; } }
+ public byte[] getBytes(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBytes( parameterIndex); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Date getDate(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getDate( parameterIndex); } catch (SQLException e) { handleException(e); return null; } }
+ public Date getDate(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getDate( parameterIndex); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Time getTime(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getTime( parameterIndex); } catch (SQLException e) { handleException(e); return null; } }
+ public Time getTime(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getTime( parameterIndex); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Timestamp getTimestamp(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getTimestamp( parameterIndex); } catch (SQLException e) { handleException(e); return null; } }
+ public Timestamp getTimestamp(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getTimestamp( parameterIndex); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Object getObject(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getObject( parameterIndex); } catch (SQLException e) { handleException(e); return null; } }
+ public Object getObject(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getObject( parameterIndex); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public BigDecimal getBigDecimal(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBigDecimal( parameterIndex); } catch (SQLException e) { handleException(e); return null; } }
+ public BigDecimal getBigDecimal(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBigDecimal( parameterIndex); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Object getObject(int i, Map<String,Class<?>> map) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getObject( i, map); } catch (SQLException e) { handleException(e); return null; } }
+ public Object getObject(final int i, final Map<String,Class<?>> map) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getObject( i, map); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Ref getRef(int i) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getRef( i); } catch (SQLException e) { handleException(e); return null; } }
+ public Ref getRef(final int i) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getRef( i); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Blob getBlob(int i) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBlob( i); } catch (SQLException e) { handleException(e); return null; } }
+ public Blob getBlob(final int i) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBlob( i); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Clob getClob(int i) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getClob( i); } catch (SQLException e) { handleException(e); return null; } }
+ public Clob getClob(final int i) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getClob( i); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Array getArray(int i) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getArray( i); } catch (SQLException e) { handleException(e); return null; } }
+ public Array getArray(final int i) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getArray( i); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Date getDate(int parameterIndex, Calendar cal) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getDate( parameterIndex, cal); } catch (SQLException e) { handleException(e); return null; } }
+ public Date getDate(final int parameterIndex, final Calendar cal) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getDate( parameterIndex, cal); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Time getTime(int parameterIndex, Calendar cal) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getTime( parameterIndex, cal); } catch (SQLException e) { handleException(e); return null; } }
+ public Time getTime(final int parameterIndex, final Calendar cal) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getTime( parameterIndex, cal); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Timestamp getTimestamp(int parameterIndex, Calendar cal) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getTimestamp( parameterIndex, cal); } catch (SQLException e) { handleException(e); return null; } }
+ public Timestamp getTimestamp(final int parameterIndex, final Calendar cal) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getTimestamp( parameterIndex, cal); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public void registerOutParameter(int paramIndex, int sqlType, String typeName) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter( paramIndex, sqlType, typeName); } catch (SQLException e) { handleException(e); } }
+ public void registerOutParameter(final int paramIndex, final int sqlType, final String typeName) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter( paramIndex, sqlType, typeName); } catch (final SQLException e) { handleException(e); } }
@Override
- public void registerOutParameter(String parameterName, int sqlType) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter(parameterName, sqlType); } catch (SQLException e) { handleException(e); } }
+ public void registerOutParameter(final String parameterName, final int sqlType) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter(parameterName, sqlType); } catch (final SQLException e) { handleException(e); } }
@Override
- public void registerOutParameter(String parameterName, int sqlType, int scale) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter(parameterName, sqlType, scale); } catch (SQLException e) { handleException(e); } }
+ public void registerOutParameter(final String parameterName, final int sqlType, final int scale) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter(parameterName, sqlType, scale); } catch (final SQLException e) { handleException(e); } }
@Override
- public void registerOutParameter(String parameterName, int sqlType, String typeName) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter(parameterName, sqlType, typeName); } catch (SQLException e) { handleException(e); } }
+ public void registerOutParameter(final String parameterName, final int sqlType, final String typeName) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).registerOutParameter(parameterName, sqlType, typeName); } catch (final SQLException e) { handleException(e); } }
@Override
- public URL getURL(int parameterIndex) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getURL(parameterIndex); } catch (SQLException e) { handleException(e); return null; } }
+ public URL getURL(final int parameterIndex) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getURL(parameterIndex); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public void setURL(String parameterName, URL val) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setURL(parameterName, val); } catch (SQLException e) { handleException(e); } }
+ public void setURL(final String parameterName, final URL val) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setURL(parameterName, val); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setNull(String parameterName, int sqlType) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setNull(parameterName, sqlType); } catch (SQLException e) { handleException(e); } }
+ public void setNull(final String parameterName, final int sqlType) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setNull(parameterName, sqlType); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setBoolean(String parameterName, boolean x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setBoolean(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setBoolean(final String parameterName, final boolean x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setBoolean(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setByte(String parameterName, byte x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setByte(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setByte(final String parameterName, final byte x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setByte(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setShort(String parameterName, short x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setShort(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setShort(final String parameterName, final short x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setShort(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setInt(String parameterName, int x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setInt(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setInt(final String parameterName, final int x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setInt(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setLong(String parameterName, long x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setLong(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setLong(final String parameterName, final long x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setLong(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setFloat(String parameterName, float x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setFloat(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setFloat(final String parameterName, final float x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setFloat(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setDouble(String parameterName, double x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setDouble(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setDouble(final String parameterName, final double x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setDouble(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setBigDecimal(String parameterName, BigDecimal x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setBigDecimal(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setBigDecimal(final String parameterName, final BigDecimal x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setBigDecimal(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setString(String parameterName, String x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setString(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setString(final String parameterName, final String x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setString(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setBytes(String parameterName, byte [] x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setBytes(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setBytes(final String parameterName, final byte [] x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setBytes(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setDate(String parameterName, Date x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setDate(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setDate(final String parameterName, final Date x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setDate(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setTime(String parameterName, Time x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setTime(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setTime(final String parameterName, final Time x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setTime(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setTimestamp(String parameterName, Timestamp x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setTimestamp(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setTimestamp(final String parameterName, final Timestamp x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setTimestamp(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setAsciiStream(String parameterName, InputStream x, int length) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setAsciiStream(parameterName, x, length); } catch (SQLException e) { handleException(e); } }
+ public void setAsciiStream(final String parameterName, final InputStream x, final int length) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setAsciiStream(parameterName, x, length); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setBinaryStream(String parameterName, InputStream x, int length) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setBinaryStream(parameterName, x, length); } catch (SQLException e) { handleException(e); } }
+ public void setBinaryStream(final String parameterName, final InputStream x, final int length) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setBinaryStream(parameterName, x, length); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setObject(String parameterName, Object x, int targetSqlType, int scale) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setObject(parameterName, x, targetSqlType, scale); } catch (SQLException e) { handleException(e); } }
+ public void setObject(final String parameterName, final Object x, final int targetSqlType, final int scale) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setObject(parameterName, x, targetSqlType, scale); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setObject(String parameterName, Object x, int targetSqlType) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setObject(parameterName, x, targetSqlType); } catch (SQLException e) { handleException(e); } }
+ public void setObject(final String parameterName, final Object x, final int targetSqlType) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setObject(parameterName, x, targetSqlType); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setObject(String parameterName, Object x) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setObject(parameterName, x); } catch (SQLException e) { handleException(e); } }
+ public void setObject(final String parameterName, final Object x) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setObject(parameterName, x); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setCharacterStream(String parameterName, Reader reader, int length) throws SQLException
+ public void setCharacterStream(final String parameterName, final Reader reader, final int length) throws SQLException
{ checkOpen(); ((CallableStatement)getDelegate()).setCharacterStream(parameterName, reader, length); }
@Override
- public void setDate(String parameterName, Date x, Calendar cal) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setDate(parameterName, x, cal); } catch (SQLException e) { handleException(e); } }
+ public void setDate(final String parameterName, final Date x, final Calendar cal) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setDate(parameterName, x, cal); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setTime(String parameterName, Time x, Calendar cal) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setTime(parameterName, x, cal); } catch (SQLException e) { handleException(e); } }
+ public void setTime(final String parameterName, final Time x, final Calendar cal) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setTime(parameterName, x, cal); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setTimestamp(String parameterName, Timestamp x, Calendar cal) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setTimestamp(parameterName, x, cal); } catch (SQLException e) { handleException(e); } }
+ public void setTimestamp(final String parameterName, final Timestamp x, final Calendar cal) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setTimestamp(parameterName, x, cal); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setNull(String parameterName, int sqlType, String typeName) throws SQLException
- { checkOpen(); try { ((CallableStatement)getDelegate()).setNull(parameterName, sqlType, typeName); } catch (SQLException e) { handleException(e); } }
+ public void setNull(final String parameterName, final int sqlType, final String typeName) throws SQLException
+ { checkOpen(); try { ((CallableStatement)getDelegate()).setNull(parameterName, sqlType, typeName); } catch (final SQLException e) { handleException(e); } }
@Override
- public String getString(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getString(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public String getString(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getString(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public boolean getBoolean(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBoolean(parameterName); } catch (SQLException e) { handleException(e); return false; } }
+ public boolean getBoolean(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBoolean(parameterName); } catch (final SQLException e) { handleException(e); return false; } }
@Override
- public byte getByte(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getByte(parameterName); } catch (SQLException e) { handleException(e); return 0; } }
+ public byte getByte(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getByte(parameterName); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public short getShort(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getShort(parameterName); } catch (SQLException e) { handleException(e); return 0; } }
+ public short getShort(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getShort(parameterName); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public int getInt(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getInt(parameterName); } catch (SQLException e) { handleException(e); return 0; } }
+ public int getInt(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getInt(parameterName); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public long getLong(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getLong(parameterName); } catch (SQLException e) { handleException(e); return 0; } }
+ public long getLong(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getLong(parameterName); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public float getFloat(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getFloat(parameterName); } catch (SQLException e) { handleException(e); return 0; } }
+ public float getFloat(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getFloat(parameterName); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public double getDouble(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getDouble(parameterName); } catch (SQLException e) { handleException(e); return 0; } }
+ public double getDouble(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getDouble(parameterName); } catch (final SQLException e) { handleException(e); return 0; } }
@Override
- public byte[] getBytes(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBytes(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public byte[] getBytes(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBytes(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Date getDate(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getDate(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public Date getDate(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getDate(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Time getTime(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getTime(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public Time getTime(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getTime(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Timestamp getTimestamp(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getTimestamp(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public Timestamp getTimestamp(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getTimestamp(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Object getObject(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getObject(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public Object getObject(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getObject(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public BigDecimal getBigDecimal(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBigDecimal(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public BigDecimal getBigDecimal(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBigDecimal(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Object getObject(String parameterName, Map<String,Class<?>> map) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getObject(parameterName, map); } catch (SQLException e) { handleException(e); return null; } }
+ public Object getObject(final String parameterName, final Map<String,Class<?>> map) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getObject(parameterName, map); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Ref getRef(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getRef(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public Ref getRef(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getRef(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Blob getBlob(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getBlob(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public Blob getBlob(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getBlob(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Clob getClob(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getClob(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public Clob getClob(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getClob(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Array getArray(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getArray(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public Array getArray(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getArray(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Date getDate(String parameterName, Calendar cal) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getDate(parameterName, cal); } catch (SQLException e) { handleException(e); return null; } }
+ public Date getDate(final String parameterName, final Calendar cal) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getDate(parameterName, cal); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Time getTime(String parameterName, Calendar cal) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getTime(parameterName, cal); } catch (SQLException e) { handleException(e); return null; } }
+ public Time getTime(final String parameterName, final Calendar cal) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getTime(parameterName, cal); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public Timestamp getTimestamp(String parameterName, Calendar cal) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getTimestamp(parameterName, cal); } catch (SQLException e) { handleException(e); return null; } }
+ public Timestamp getTimestamp(final String parameterName, final Calendar cal) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getTimestamp(parameterName, cal); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public URL getURL(String parameterName) throws SQLException
- { checkOpen(); try { return ((CallableStatement)getDelegate()).getURL(parameterName); } catch (SQLException e) { handleException(e); return null; } }
+ public URL getURL(final String parameterName) throws SQLException
+ { checkOpen(); try { return ((CallableStatement)getDelegate()).getURL(parameterName); } catch (final SQLException e) { handleException(e); return null; } }
@Override
- public RowId getRowId(int parameterIndex) throws SQLException {
+ public RowId getRowId(final int parameterIndex) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getRowId(parameterIndex);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public RowId getRowId(String parameterName) throws SQLException {
+ public RowId getRowId(final String parameterName) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getRowId(parameterName);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public void setRowId(String parameterName, RowId value) throws SQLException {
+ public void setRowId(final String parameterName, final RowId value) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setRowId(parameterName, value);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setNString(String parameterName, String value) throws SQLException {
+ public void setNString(final String parameterName, final String value) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setNString(parameterName, value);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setNCharacterStream(String parameterName, Reader reader, long length) throws SQLException {
+ public void setNCharacterStream(final String parameterName, final Reader reader, final long length) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setNCharacterStream(parameterName, reader, length);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setNClob(String parameterName, NClob value) throws SQLException {
+ public void setNClob(final String parameterName, final NClob value) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setNClob(parameterName, value);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setClob(String parameterName, Reader reader, long length) throws SQLException {
+ public void setClob(final String parameterName, final Reader reader, final long length) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setClob(parameterName, reader, length);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setBlob(String parameterName, InputStream inputStream, long length) throws SQLException {
+ public void setBlob(final String parameterName, final InputStream inputStream, final long length) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setBlob(parameterName, inputStream, length);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setNClob(String parameterName, Reader reader, long length) throws SQLException {
+ public void setNClob(final String parameterName, final Reader reader, final long length) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setNClob(parameterName, reader, length);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public NClob getNClob(int parameterIndex) throws SQLException {
+ public NClob getNClob(final int parameterIndex) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getNClob(parameterIndex);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public NClob getNClob(String parameterName) throws SQLException {
+ public NClob getNClob(final String parameterName) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getNClob(parameterName);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public void setSQLXML(String parameterName, SQLXML value) throws SQLException {
+ public void setSQLXML(final String parameterName, final SQLXML value) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setSQLXML(parameterName, value);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public SQLXML getSQLXML(int parameterIndex) throws SQLException {
+ public SQLXML getSQLXML(final int parameterIndex) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getSQLXML(parameterIndex);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public SQLXML getSQLXML(String parameterName) throws SQLException {
+ public SQLXML getSQLXML(final String parameterName) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getSQLXML(parameterName);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public String getNString(int parameterIndex) throws SQLException {
+ public String getNString(final int parameterIndex) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getNString(parameterIndex);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public String getNString(String parameterName) throws SQLException {
+ public String getNString(final String parameterName) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getNString(parameterName);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public Reader getNCharacterStream(int parameterIndex) throws SQLException {
+ public Reader getNCharacterStream(final int parameterIndex) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getNCharacterStream(parameterIndex);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public Reader getNCharacterStream(String parameterName) throws SQLException {
+ public Reader getNCharacterStream(final String parameterName) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getNCharacterStream(parameterName);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public Reader getCharacterStream(int parameterIndex) throws SQLException {
+ public Reader getCharacterStream(final int parameterIndex) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getCharacterStream(parameterIndex);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public Reader getCharacterStream(String parameterName) throws SQLException {
+ public Reader getCharacterStream(final String parameterName) throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getCharacterStream(parameterName);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public void setBlob(String parameterName, Blob blob) throws SQLException {
+ public void setBlob(final String parameterName, final Blob blob) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setBlob(parameterName, blob);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setClob(String parameterName, Clob clob) throws SQLException {
+ public void setClob(final String parameterName, final Clob clob) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setClob(parameterName, clob);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setAsciiStream(String parameterName, InputStream inputStream, long length) throws SQLException {
+ public void setAsciiStream(final String parameterName, final InputStream inputStream, final long length) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setAsciiStream(parameterName, inputStream, length);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setBinaryStream(String parameterName, InputStream inputStream, long length) throws SQLException {
+ public void setBinaryStream(final String parameterName, final InputStream inputStream, final long length) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setBinaryStream(parameterName, inputStream, length);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setCharacterStream(String parameterName, Reader reader, long length) throws SQLException {
+ public void setCharacterStream(final String parameterName, final Reader reader, final long length) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setCharacterStream(parameterName, reader, length);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setAsciiStream(String parameterName, InputStream inputStream) throws SQLException {
+ public void setAsciiStream(final String parameterName, final InputStream inputStream) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setAsciiStream(parameterName, inputStream);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setBinaryStream(String parameterName, InputStream inputStream) throws SQLException {
+ public void setBinaryStream(final String parameterName, final InputStream inputStream) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setBinaryStream(parameterName, inputStream);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setCharacterStream(String parameterName, Reader reader) throws SQLException {
+ public void setCharacterStream(final String parameterName, final Reader reader) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setCharacterStream(parameterName, reader);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setNCharacterStream(String parameterName, Reader reader) throws SQLException {
+ public void setNCharacterStream(final String parameterName, final Reader reader) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setNCharacterStream(parameterName, reader);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setClob(String parameterName, Reader reader) throws SQLException {
+ public void setClob(final String parameterName, final Reader reader) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setClob(parameterName, reader);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setBlob(String parameterName, InputStream inputStream) throws SQLException {
+ public void setBlob(final String parameterName, final InputStream inputStream) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setBlob(parameterName, inputStream);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setNClob(String parameterName, Reader reader) throws SQLException {
+ public void setNClob(final String parameterName, final Reader reader) throws SQLException {
checkOpen();
try {
((CallableStatement)getDelegate()).setNClob(parameterName, reader);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public <T> T getObject(int parameterIndex, Class<T> type)
+ public <T> T getObject(final int parameterIndex, final Class<T> type)
throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getObject(parameterIndex, type);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public <T> T getObject(String parameterName, Class<T> type)
+ public <T> T getObject(final String parameterName, final Class<T> type)
throws SQLException {
checkOpen();
try {
return ((CallableStatement)getDelegate()).getObject(parameterName, type);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
Modified: tomcat/trunk/java/org/apache/tomcat/dbcp/dbcp2/DelegatingConnection.java
URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/dbcp/dbcp2/DelegatingConnection.java?rev=1743697&r1=1743696&r2=1743697&view=diff
==============================================================================
--- tomcat/trunk/java/org/apache/tomcat/dbcp/dbcp2/DelegatingConnection.java (original)
+++ tomcat/trunk/java/org/apache/tomcat/dbcp/dbcp2/DelegatingConnection.java Fri May 13 16:35:33 2016
@@ -86,7 +86,7 @@ public class DelegatingConnection<C exte
*
* @param c the {@link Connection} to delegate all calls to.
*/
- public DelegatingConnection(C c) {
+ public DelegatingConnection(final C c) {
super();
_conn = c;
}
@@ -100,16 +100,16 @@ public class DelegatingConnection<C exte
public String toString() {
String s = null;
- Connection c = this.getInnermostDelegateInternal();
+ final Connection c = this.getInnermostDelegateInternal();
if (c != null) {
try {
if (c.isClosed()) {
s = "connection is closed";
}
else {
- StringBuffer sb = new StringBuffer();
+ final StringBuffer sb = new StringBuffer();
sb.append(hashCode());
- DatabaseMetaData meta = c.getMetaData();
+ final DatabaseMetaData meta = c.getMetaData();
if (meta != null) {
sb.append(", URL=");
sb.append(meta.getURL());
@@ -121,7 +121,7 @@ public class DelegatingConnection<C exte
}
}
}
- catch (SQLException ex) {
+ catch (final SQLException ex) {
// Ignore
}
}
@@ -151,8 +151,8 @@ public class DelegatingConnection<C exte
* @param c connection to compare innermost delegate with
* @return true if innermost delegate equals <code>c</code>
*/
- public boolean innermostDelegateEquals(Connection c) {
- Connection innerCon = getInnermostDelegateInternal();
+ public boolean innermostDelegateEquals(final Connection c) {
+ final Connection innerCon = getInnermostDelegateInternal();
if (innerCon == null) {
return c == null;
}
@@ -202,7 +202,7 @@ public class DelegatingConnection<C exte
* Sets my delegate.
* @param c The connection
*/
- public void setDelegate(C c) {
+ public void setDelegate(final C c) {
_conn = c;
}
@@ -228,7 +228,7 @@ public class DelegatingConnection<C exte
return _closed;
}
- protected void setClosedInternal(boolean closed) {
+ protected void setClosedInternal(final boolean closed) {
this._closed = closed;
}
@@ -248,11 +248,11 @@ public class DelegatingConnection<C exte
}
}
- protected void handleException(SQLException e) throws SQLException {
+ protected void handleException(final SQLException e) throws SQLException {
throw e;
}
- private void initializeStatement(DelegatingStatement ds) throws SQLException {
+ private void initializeStatement(final DelegatingStatement ds) throws SQLException {
if (defaultQueryTimeout != null &&
defaultQueryTimeout.intValue() != ds.getQueryTimeout()) {
ds.setQueryTimeout(defaultQueryTimeout.intValue());
@@ -263,92 +263,92 @@ public class DelegatingConnection<C exte
public Statement createStatement() throws SQLException {
checkOpen();
try {
- DelegatingStatement ds =
+ final DelegatingStatement ds =
new DelegatingStatement(this, _conn.createStatement());
initializeStatement(ds);
return ds;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public Statement createStatement(int resultSetType,
- int resultSetConcurrency) throws SQLException {
+ public Statement createStatement(final int resultSetType,
+ final int resultSetConcurrency) throws SQLException {
checkOpen();
try {
- DelegatingStatement ds = new DelegatingStatement(
+ final DelegatingStatement ds = new DelegatingStatement(
this, _conn.createStatement(resultSetType,resultSetConcurrency));
initializeStatement(ds);
return ds;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public PreparedStatement prepareStatement(String sql) throws SQLException {
+ public PreparedStatement prepareStatement(final String sql) throws SQLException {
checkOpen();
try {
- DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
+ final DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
this, _conn.prepareStatement(sql));
initializeStatement(dps);
return dps;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public PreparedStatement prepareStatement(String sql,
- int resultSetType,
- int resultSetConcurrency) throws SQLException {
+ public PreparedStatement prepareStatement(final String sql,
+ final int resultSetType,
+ final int resultSetConcurrency) throws SQLException {
checkOpen();
try {
- DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
+ final DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
this, _conn.prepareStatement(sql,resultSetType,resultSetConcurrency));
initializeStatement(dps);
return dps;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public CallableStatement prepareCall(String sql) throws SQLException {
+ public CallableStatement prepareCall(final String sql) throws SQLException {
checkOpen();
try {
- DelegatingCallableStatement dcs =
+ final DelegatingCallableStatement dcs =
new DelegatingCallableStatement(this, _conn.prepareCall(sql));
initializeStatement(dcs);
return dcs;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public CallableStatement prepareCall(String sql,
- int resultSetType,
- int resultSetConcurrency) throws SQLException {
+ public CallableStatement prepareCall(final String sql,
+ final int resultSetType,
+ final int resultSetConcurrency) throws SQLException {
checkOpen();
try {
- DelegatingCallableStatement dcs = new DelegatingCallableStatement(
+ final DelegatingCallableStatement dcs = new DelegatingCallableStatement(
this, _conn.prepareCall(sql, resultSetType,resultSetConcurrency));
initializeStatement(dcs);
return dcs;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
@@ -360,7 +360,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
_conn.clearWarnings();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
}
}
@@ -371,7 +371,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
_conn.commit();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
}
}
@@ -395,7 +395,7 @@ public class DelegatingConnection<C exte
try {
_autoCommitCached = Boolean.valueOf(_conn.getAutoCommit());
return _autoCommitCached.booleanValue();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return false;
}
@@ -407,7 +407,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
return _conn.getCatalog();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return null;
}
@@ -419,7 +419,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
return new DelegatingDatabaseMetaData(this, _conn.getMetaData());
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return null;
}
@@ -431,7 +431,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
return _conn.getTransactionIsolation();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return -1;
}
@@ -443,7 +443,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
return _conn.getTypeMap();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return null;
}
@@ -455,7 +455,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
return _conn.getWarnings();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return null;
}
@@ -471,7 +471,7 @@ public class DelegatingConnection<C exte
try {
_readOnlyCached = Boolean.valueOf(_conn.isReadOnly());
return _readOnlyCached.booleanValue();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return false;
}
@@ -479,11 +479,11 @@ public class DelegatingConnection<C exte
@Override
- public String nativeSQL(String sql) throws SQLException {
+ public String nativeSQL(final String sql) throws SQLException {
checkOpen();
try {
return _conn.nativeSQL(sql);
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return null;
}
@@ -495,7 +495,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
_conn.rollback();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
}
}
@@ -518,7 +518,7 @@ public class DelegatingConnection<C exte
* default will be used.
* @param defaultQueryTimeout The timeout value
*/
- public void setDefaultQueryTimeout(Integer defaultQueryTimeout) {
+ public void setDefaultQueryTimeout(final Integer defaultQueryTimeout) {
this.defaultQueryTimeout = defaultQueryTimeout;
}
@@ -528,7 +528,7 @@ public class DelegatingConnection<C exte
*
* @param cacheState The new value for the state caching flag
*/
- public void setCacheState(boolean cacheState) {
+ public void setCacheState(final boolean cacheState) {
this._cacheState = cacheState;
}
@@ -545,32 +545,32 @@ public class DelegatingConnection<C exte
}
@Override
- public void setAutoCommit(boolean autoCommit) throws SQLException {
+ public void setAutoCommit(final boolean autoCommit) throws SQLException {
checkOpen();
try {
_conn.setAutoCommit(autoCommit);
if (_cacheState) {
_autoCommitCached = Boolean.valueOf(autoCommit);
}
- } catch (SQLException e) {
+ } catch (final SQLException e) {
_autoCommitCached = null;
handleException(e);
}
}
@Override
- public void setCatalog(String catalog) throws SQLException
- { checkOpen(); try { _conn.setCatalog(catalog); } catch (SQLException e) { handleException(e); } }
+ public void setCatalog(final String catalog) throws SQLException
+ { checkOpen(); try { _conn.setCatalog(catalog); } catch (final SQLException e) { handleException(e); } }
@Override
- public void setReadOnly(boolean readOnly) throws SQLException {
+ public void setReadOnly(final boolean readOnly) throws SQLException {
checkOpen();
try {
_conn.setReadOnly(readOnly);
if (_cacheState) {
_readOnlyCached = Boolean.valueOf(readOnly);
}
- } catch (SQLException e) {
+ } catch (final SQLException e) {
_readOnlyCached = null;
handleException(e);
}
@@ -578,22 +578,22 @@ public class DelegatingConnection<C exte
@Override
- public void setTransactionIsolation(int level) throws SQLException {
+ public void setTransactionIsolation(final int level) throws SQLException {
checkOpen();
try {
_conn.setTransactionIsolation(level);
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setTypeMap(Map<String,Class<?>> map) throws SQLException {
+ public void setTypeMap(final Map<String,Class<?>> map) throws SQLException {
checkOpen();
try {
_conn.setTypeMap(map);
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
}
}
@@ -610,7 +610,7 @@ public class DelegatingConnection<C exte
String label = "";
try {
label = _conn.toString();
- } catch (Exception ex) {
+ } catch (final Exception ex) {
// ignore, leave label empty
}
throw new SQLException
@@ -633,11 +633,11 @@ public class DelegatingConnection<C exte
// The JDBC spec requires that a Connection close any open
// Statement's when it is closed.
// DBCP-288. Not all the traced objects will be statements
- List<AbandonedTrace> traces = getTrace();
+ final List<AbandonedTrace> traces = getTrace();
if(traces != null && traces.size() > 0) {
- Iterator<AbandonedTrace> traceIter = traces.iterator();
+ final Iterator<AbandonedTrace> traceIter = traces.iterator();
while (traceIter.hasNext()) {
- Object trace = traceIter.next();
+ final Object trace = traceIter.next();
if (trace instanceof Statement) {
((Statement) trace).close();
} else if (trace instanceof ResultSet) {
@@ -657,7 +657,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
return _conn.getHoldability();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return 0;
}
@@ -665,11 +665,11 @@ public class DelegatingConnection<C exte
@Override
- public void setHoldability(int holdability) throws SQLException {
+ public void setHoldability(final int holdability) throws SQLException {
checkOpen();
try {
_conn.setHoldability(holdability);
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
}
}
@@ -680,7 +680,7 @@ public class DelegatingConnection<C exte
checkOpen();
try {
return _conn.setSavepoint();
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return null;
}
@@ -688,11 +688,11 @@ public class DelegatingConnection<C exte
@Override
- public Savepoint setSavepoint(String name) throws SQLException {
+ public Savepoint setSavepoint(final String name) throws SQLException {
checkOpen();
try {
return _conn.setSavepoint(name);
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
return null;
}
@@ -700,122 +700,122 @@ public class DelegatingConnection<C exte
@Override
- public void rollback(Savepoint savepoint) throws SQLException {
+ public void rollback(final Savepoint savepoint) throws SQLException {
checkOpen();
try {
_conn.rollback(savepoint);
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void releaseSavepoint(Savepoint savepoint)
+ public void releaseSavepoint(final Savepoint savepoint)
throws SQLException {
checkOpen();
try {
_conn.releaseSavepoint(savepoint);
- } catch (SQLException e) {
+ } catch (final SQLException e) {
handleException(e);
}
}
@Override
- public Statement createStatement(int resultSetType,
- int resultSetConcurrency,
- int resultSetHoldability) throws SQLException {
+ public Statement createStatement(final int resultSetType,
+ final int resultSetConcurrency,
+ final int resultSetHoldability) throws SQLException {
checkOpen();
try {
- DelegatingStatement ds = new DelegatingStatement(this,
+ final DelegatingStatement ds = new DelegatingStatement(this,
_conn.createStatement(resultSetType, resultSetConcurrency,
resultSetHoldability));
initializeStatement(ds);
return ds;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public PreparedStatement prepareStatement(String sql, int resultSetType,
- int resultSetConcurrency,
- int resultSetHoldability) throws SQLException {
+ public PreparedStatement prepareStatement(final String sql, final int resultSetType,
+ final int resultSetConcurrency,
+ final int resultSetHoldability) throws SQLException {
checkOpen();
try {
- DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
+ final DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
this, _conn.prepareStatement(sql, resultSetType,
resultSetConcurrency, resultSetHoldability));
initializeStatement(dps);
return dps;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public CallableStatement prepareCall(String sql, int resultSetType,
- int resultSetConcurrency,
- int resultSetHoldability) throws SQLException {
+ public CallableStatement prepareCall(final String sql, final int resultSetType,
+ final int resultSetConcurrency,
+ final int resultSetHoldability) throws SQLException {
checkOpen();
try {
- DelegatingCallableStatement dcs = new DelegatingCallableStatement(
+ final DelegatingCallableStatement dcs = new DelegatingCallableStatement(
this, _conn.prepareCall(sql, resultSetType,
resultSetConcurrency, resultSetHoldability));
initializeStatement(dcs);
return dcs;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public PreparedStatement prepareStatement(String sql, int autoGeneratedKeys) throws SQLException {
+ public PreparedStatement prepareStatement(final String sql, final int autoGeneratedKeys) throws SQLException {
checkOpen();
try {
- DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
+ final DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
this, _conn.prepareStatement(sql, autoGeneratedKeys));
initializeStatement(dps);
return dps;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public PreparedStatement prepareStatement(String sql, int columnIndexes[]) throws SQLException {
+ public PreparedStatement prepareStatement(final String sql, final int columnIndexes[]) throws SQLException {
checkOpen();
try {
- DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
+ final DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
this, _conn.prepareStatement(sql, columnIndexes));
initializeStatement(dps);
return dps;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public PreparedStatement prepareStatement(String sql, String columnNames[]) throws SQLException {
+ public PreparedStatement prepareStatement(final String sql, final String columnNames[]) throws SQLException {
checkOpen();
try {
- DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
+ final DelegatingPreparedStatement dps = new DelegatingPreparedStatement(
this, _conn.prepareStatement(sql, columnNames));
initializeStatement(dps);
return dps;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
@@ -823,7 +823,7 @@ public class DelegatingConnection<C exte
@Override
- public boolean isWrapperFor(Class<?> iface) throws SQLException {
+ public boolean isWrapperFor(final Class<?> iface) throws SQLException {
if (iface.isAssignableFrom(getClass())) {
return true;
} else if (iface.isAssignableFrom(_conn.getClass())) {
@@ -834,7 +834,7 @@ public class DelegatingConnection<C exte
}
@Override
- public <T> T unwrap(Class<T> iface) throws SQLException {
+ public <T> T unwrap(final Class<T> iface) throws SQLException {
if (iface.isAssignableFrom(getClass())) {
return iface.cast(this);
} else if (iface.isAssignableFrom(_conn.getClass())) {
@@ -845,12 +845,12 @@ public class DelegatingConnection<C exte
}
@Override
- public Array createArrayOf(String typeName, Object[] elements) throws SQLException {
+ public Array createArrayOf(final String typeName, final Object[] elements) throws SQLException {
checkOpen();
try {
return _conn.createArrayOf(typeName, elements);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
@@ -862,7 +862,7 @@ public class DelegatingConnection<C exte
try {
return _conn.createBlob();
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
@@ -874,7 +874,7 @@ public class DelegatingConnection<C exte
try {
return _conn.createClob();
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
@@ -886,7 +886,7 @@ public class DelegatingConnection<C exte
try {
return _conn.createNClob();
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
@@ -898,62 +898,62 @@ public class DelegatingConnection<C exte
try {
return _conn.createSQLXML();
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public Struct createStruct(String typeName, Object[] attributes) throws SQLException {
+ public Struct createStruct(final String typeName, final Object[] attributes) throws SQLException {
checkOpen();
try {
return _conn.createStruct(typeName, attributes);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public boolean isValid(int timeout) throws SQLException {
+ public boolean isValid(final int timeout) throws SQLException {
if (isClosed()) {
return false;
}
try {
return _conn.isValid(timeout);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return false;
}
}
@Override
- public void setClientInfo(String name, String value) throws SQLClientInfoException {
+ public void setClientInfo(final String name, final String value) throws SQLClientInfoException {
try {
checkOpen();
_conn.setClientInfo(name, value);
}
- catch (SQLClientInfoException e) {
+ catch (final SQLClientInfoException e) {
throw e;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
throw new SQLClientInfoException("Connection is closed.", EMPTY_FAILED_PROPERTIES, e);
}
}
@Override
- public void setClientInfo(Properties properties) throws SQLClientInfoException {
+ public void setClientInfo(final Properties properties) throws SQLClientInfoException {
try {
checkOpen();
_conn.setClientInfo(properties);
}
- catch (SQLClientInfoException e) {
+ catch (final SQLClientInfoException e) {
throw e;
}
- catch (SQLException e) {
+ catch (final SQLException e) {
throw new SQLClientInfoException("Connection is closed.", EMPTY_FAILED_PROPERTIES, e);
}
}
@@ -964,31 +964,31 @@ public class DelegatingConnection<C exte
try {
return _conn.getClientInfo();
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public String getClientInfo(String name) throws SQLException {
+ public String getClientInfo(final String name) throws SQLException {
checkOpen();
try {
return _conn.getClientInfo(name);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public void setSchema(String schema) throws SQLException {
+ public void setSchema(final String schema) throws SQLException {
checkOpen();
try {
_conn.setSchema(schema);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@@ -999,31 +999,31 @@ public class DelegatingConnection<C exte
try {
return _conn.getSchema();
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return null;
}
}
@Override
- public void abort(Executor executor) throws SQLException {
+ public void abort(final Executor executor) throws SQLException {
checkOpen();
try {
_conn.abort(executor);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@Override
- public void setNetworkTimeout(Executor executor, int milliseconds)
+ public void setNetworkTimeout(final Executor executor, final int milliseconds)
throws SQLException {
checkOpen();
try {
_conn.setNetworkTimeout(executor, milliseconds);
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
}
}
@@ -1034,7 +1034,7 @@ public class DelegatingConnection<C exte
try {
return _conn.getNetworkTimeout();
}
- catch (SQLException e) {
+ catch (final SQLException e) {
handleException(e);
return 0;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org