Re-added SuppressWarnings(deprecation) from internal code
This commit is contained in:
parent
462dabafcf
commit
85517bf19d
@ -1,19 +1,14 @@
|
||||
package org.jooq.kotlin
|
||||
|
||||
import org.jooq.SQLDialect
|
||||
import org.jooq.SQLDialect.H2
|
||||
import org.jooq.impl.DSL
|
||||
import org.jooq.impl.DSL.*
|
||||
import org.jooq.impl.SQLDataType
|
||||
import org.jooq.impl.SQLDataType.INTEGER
|
||||
import org.junit.Assert
|
||||
import org.junit.Assert.assertEquals
|
||||
import org.junit.FixMethodOrder
|
||||
import org.junit.Test
|
||||
import org.junit.runners.MethodSorters
|
||||
|
||||
import kotlin.io.*
|
||||
|
||||
@FixMethodOrder(MethodSorters.NAME_ASCENDING)
|
||||
class ExtensionsTest {
|
||||
|
||||
|
||||
@ -172,6 +172,7 @@ public abstract class AbstractTypedElementDefinition<T extends Definition>
|
||||
return result;
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
public static final DataTypeDefinition mapDefinedType(Definition container, Definition child, DataTypeDefinition definedType, JavaTypeResolver resolver) {
|
||||
DataTypeDefinition result = definedType;
|
||||
Database db = container.getDatabase();
|
||||
@ -310,6 +311,7 @@ public abstract class AbstractTypedElementDefinition<T extends Definition>
|
||||
return result;
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
public static final CustomType customType(Database db, ForcedType forcedType) {
|
||||
String name = forcedType.getName();
|
||||
|
||||
|
||||
@ -75,6 +75,7 @@ public class Databases {
|
||||
/**
|
||||
* Get a reference to a {@link Database} class for a given {@link SQLDialect}.
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
public static final Class<? extends Database> databaseClass(SQLDialect dialect) {
|
||||
Class<? extends Database> result = JDBCDatabase.class;
|
||||
|
||||
|
||||
@ -150,6 +150,7 @@ public @interface Allow {
|
||||
* A list of jOOQ {@link SQLDialect} which are required on any jOOQ API
|
||||
* method that is annotated with {@link Support}.
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
SQLDialect[] value() default {
|
||||
|
||||
|
||||
|
||||
@ -274,6 +274,7 @@ abstract class AbstractBindContext extends AbstractContext<BindContext> implemen
|
||||
/**
|
||||
* Subclasses may override this method to achieve different behaviour
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
protected void bindInternal(QueryPartInternal internal) {
|
||||
internal.accept(this);
|
||||
}
|
||||
|
||||
@ -157,6 +157,7 @@ abstract class AbstractQuery extends AbstractQueryPart implements Query {
|
||||
* <p>
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
@Override
|
||||
public Query bind(String param, Object value) {
|
||||
Integer index = Ints.tryParse(param);
|
||||
@ -183,6 +184,7 @@ abstract class AbstractQuery extends AbstractQueryPart implements Query {
|
||||
* <p>
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
@Override
|
||||
public Query bind(int index, Object value) {
|
||||
Param<?>[] params = getParams().values().toArray(EMPTY_PARAM);
|
||||
|
||||
@ -483,5 +483,6 @@ package org.jooq.impl;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -20860,6 +20860,7 @@ public class DSL {
|
||||
*
|
||||
* @see #val(Object)
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
@Support
|
||||
public static <T> Param<T> inline(T value) {
|
||||
Param<T> val = val(value);
|
||||
@ -21663,6 +21664,7 @@ public class DSL {
|
||||
*
|
||||
* @see #val(Object, Class)
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
@Support
|
||||
public static <T> Param<T> inline(Object value, Class<T> type) {
|
||||
Param<T> val = val(value, type);
|
||||
@ -21685,6 +21687,7 @@ public class DSL {
|
||||
*
|
||||
* @see #val(Object, Field)
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
@Support
|
||||
public static <T> Param<T> inline(Object value, Field<T> field) {
|
||||
Param<T> val = val(value, field);
|
||||
@ -21707,6 +21710,7 @@ public class DSL {
|
||||
*
|
||||
* @see #val(Object, DataType)
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
@Support
|
||||
public static <T> Param<T> inline(Object value, DataType<T> type) {
|
||||
Param<T> val = val(value, type);
|
||||
@ -22171,6 +22175,7 @@ public class DSL {
|
||||
* @param dataType The coercion data type
|
||||
* @return The most specific data type
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
private static <T> DataType<T> mostSpecific(T value, DataType<T> dataType) {
|
||||
|
||||
// [#3888] With custom data type conversion, users may wish to
|
||||
|
||||
@ -838,6 +838,7 @@ public class DefaultDataType<T> implements DataType<T> {
|
||||
return asConvertedDataType(DefaultBinding.newBinding(converter, this, null));
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
@Override
|
||||
public /* non-final */ <U> DataType<U> asConvertedDataType(Binding<? super T, U> newBinding) {
|
||||
if (binding == newBinding)
|
||||
|
||||
@ -76,6 +76,7 @@ final class DiagnosticsConnection extends DefaultConnection {
|
||||
final Parser parser;
|
||||
final DiagnosticsListeners listeners;
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
DiagnosticsConnection(Configuration configuration) {
|
||||
super(configuration.connectionProvider().acquire());
|
||||
|
||||
|
||||
@ -134,6 +134,7 @@ implements
|
||||
/**
|
||||
* Extracted method for type-safety
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
private final <T> void selfJoin(org.jooq.ConditionProvider selfJoin, Table<?> outer, Table<?> inner, Field<T> field) {
|
||||
Field<T> outerField = outer.field(field);
|
||||
Field<T> innerField = inner.field(field);
|
||||
|
||||
@ -2818,6 +2818,7 @@ final class Tools {
|
||||
/**
|
||||
* Map a {@link Catalog} according to the configured {@link org.jooq.SchemaMapping}
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
static final Catalog getMappedCatalog(Configuration configuration, Catalog catalog) {
|
||||
if (configuration != null) {
|
||||
org.jooq.SchemaMapping mapping = configuration.schemaMapping();
|
||||
@ -2832,6 +2833,7 @@ final class Tools {
|
||||
/**
|
||||
* Map a {@link Schema} according to the configured {@link org.jooq.SchemaMapping}
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
static final Schema getMappedSchema(Configuration configuration, Schema schema) {
|
||||
if (configuration != null) {
|
||||
org.jooq.SchemaMapping mapping = configuration.schemaMapping();
|
||||
@ -2846,6 +2848,7 @@ final class Tools {
|
||||
/**
|
||||
* Map a {@link Table} according to the configured {@link org.jooq.SchemaMapping}
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
static final <R extends Record> Table<R> getMappedTable(Configuration configuration, Table<R> table) {
|
||||
if (configuration != null) {
|
||||
org.jooq.SchemaMapping mapping = configuration.schemaMapping();
|
||||
|
||||
@ -181,6 +181,7 @@ public class MockResultSet extends JDBC41ResultSet implements ResultSet, Seriali
|
||||
return cal.getTimeInMillis();
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
private Timestamp withTZ(Timestamp timestamp, Calendar cal) {
|
||||
if (timestamp == null)
|
||||
return null;
|
||||
@ -200,6 +201,7 @@ public class MockResultSet extends JDBC41ResultSet implements ResultSet, Seriali
|
||||
return r;
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
private Time withTZ(Time time, Calendar cal) {
|
||||
if (time == null)
|
||||
return null;
|
||||
@ -212,6 +214,7 @@ public class MockResultSet extends JDBC41ResultSet implements ResultSet, Seriali
|
||||
return new Time(getMillis(cal, 1970, 0, 1, hour, minute, second, millis));
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
private Date withTZ(Date date, Calendar cal) {
|
||||
if (date == null)
|
||||
return null;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user