Fixed compilation issues on JDK 7 and JDK 8. Refactored the DataSourceAdapter abstract, supporting class to implement the Java 7 DataSource.getParentLogger():Logger method.

This commit is contained in:
John Blum
2014-04-13 17:42:57 -07:00
parent fe15c81da1
commit 4ae0be7860

View File

@@ -19,12 +19,15 @@ package org.springframework.data.gemfire.test.support;
import java.io.PrintWriter;
import java.sql.Connection;
import java.sql.SQLException;
import java.sql.SQLFeatureNotSupportedException;
import java.util.logging.Logger;
import javax.sql.DataSource;
/**
* The DataSourceAdapter class is an implementation of the DataSource interface with unsupported operations by default.
* <p/>
* @author John Blum
* @see java.sql.Connection
* @see javax.sql.DataSource
* @since 1.3.4
*/
@@ -63,6 +66,11 @@ public abstract class DataSourceAdapter implements DataSource {
throw new UnsupportedOperationException(UNSUPPORTED_OPERATION_EXCEPTION_MESSAGE);
}
//@Override
public Logger getParentLogger() throws SQLFeatureNotSupportedException {
throw new UnsupportedOperationException(UNSUPPORTED_OPERATION_EXCEPTION_MESSAGE);
}
@Override
public boolean isWrapperFor(final Class<?> iface) throws SQLException {
throw new UnsupportedOperationException(UNSUPPORTED_OPERATION_EXCEPTION_MESSAGE);