[jOOQ/jOOQ#12533] Move more Internal annotation usage to JetBrains

This commit is contained in:
Lukas Eder 2022-02-15 08:41:01 +01:00
parent 0846133b6f
commit c64f5e9344
23 changed files with 81 additions and 91 deletions

View File

@ -59,5 +59,6 @@ import java.lang.annotation.Target;
@Retention(RetentionPolicy.CLASS)
@Target(value = { FIELD, METHOD, TYPE, ANNOTATION_TYPE })
@Internal
@org.jetbrains.annotations.ApiStatus.Internal
public @interface Internal {
}

View File

@ -55,7 +55,7 @@ import org.jooq.UniqueKey;
* @deprecated - [#6875] [#7158] - 3.11.0 - Please re-generate your code
*/
@Deprecated
@org.jooq.Internal
@org.jetbrains.annotations.ApiStatus.Internal
public abstract class AbstractKeys {
/**

View File

@ -162,7 +162,7 @@ import org.jooq.tools.reflect.Reflect;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@org.jetbrains.annotations.ApiStatus.Internal
public abstract class AbstractRoutine<T>
extends
AbstractNamed

View File

@ -394,8 +394,6 @@ package org.jooq.impl;

View File

@ -43,22 +43,21 @@ import static org.jooq.impl.Tools.getMappedCatalog;
import java.util.Collections;
import java.util.List;
import java.util.function.BiFunction;
import java.util.function.Predicate;
import java.util.stream.Stream;
import org.jooq.Catalog;
import org.jooq.Clause;
import org.jooq.Comment;
import org.jooq.Context;
import org.jooq.Function1;
import org.jooq.Name;
import org.jooq.Schema;
// ...
import org.jooq.QueryPart;
// ...
import org.jooq.Schema;
// ...
import org.jooq.tools.StringUtils;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A common base class for database catalogs
* <p>
@ -66,7 +65,7 @@ import org.jooq.tools.StringUtils;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class CatalogImpl extends AbstractNamed implements Catalog {
private static final Clause[] CLAUSES = { CATALOG, CATALOG_REFERENCE };
static final Catalog DEFAULT_CATALOG = new CatalogImpl("");

View File

@ -43,6 +43,8 @@ import org.jooq.Configuration;
import org.jooq.DSLContext;
import org.jooq.migrations.xml.jaxb.MigrationsType;
import org.jetbrains.annotations.ApiStatus.Experimental;
/**
* A default implementation of the {@link CommitProvider} SPI, which provides
* a materialisation of the currently available database version graph.
@ -51,7 +53,7 @@ import org.jooq.migrations.xml.jaxb.MigrationsType;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Experimental
public class DefaultCommitProvider implements CommitProvider {
private final DSLContext ctx;

View File

@ -117,6 +117,8 @@ import org.jooq.types.UInteger;
import org.jooq.types.ULong;
import org.jooq.types.UShort;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A common base class for data types.
* <p>
@ -127,7 +129,7 @@ import org.jooq.types.UShort;
* @author Lukas Eder
*/
@SuppressWarnings({"unchecked"})
@org.jooq.Internal
@Internal
public class DefaultDataType<T> extends AbstractDataTypeX<T> {
private static final Set<SQLDialect> ENCODED_TIMESTAMP_PRECISION = SQLDialect.supportedBy(HSQLDB, MARIADB);

View File

@ -46,6 +46,8 @@ import org.jooq.Field;
import org.jooq.Row;
import org.jooq.TableField;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A record implementation for a record originating from a single table
* <p>
@ -53,7 +55,7 @@ import org.jooq.TableField;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class EmbeddableRecordImpl<R extends EmbeddableRecord<R>> extends AbstractRecord implements EmbeddableRecord<R> {
/**

View File

@ -100,6 +100,7 @@ import org.reactivestreams.Subscription;
* @author Lukas Eder
*/
@org.jooq.Internal
@org.jetbrains.annotations.ApiStatus.Internal
public final class Internal {
/**

View File

@ -38,19 +38,17 @@
package org.jooq.impl;
import java.util.List;
import java.util.function.BiFunction;
import java.util.function.Predicate;
import java.util.stream.Stream;
import org.jooq.Catalog;
import org.jooq.Context;
import org.jooq.Function1;
import org.jooq.Internal;
import org.jooq.Name;
import org.jooq.Schema;
// ...
import org.jooq.QueryPart;
// ...
import org.jooq.Schema;
// ...
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A schema that references a lazy initialisable {@link Catalog} singleton, for

View File

@ -38,8 +38,6 @@
package org.jooq.impl;
import java.util.List;
import java.util.function.BiFunction;
import java.util.function.Predicate;
import java.util.stream.Stream;
import org.jooq.Catalog;
@ -47,18 +45,18 @@ import org.jooq.Comment;
import org.jooq.Context;
import org.jooq.Domain;
import org.jooq.ForeignKey;
import org.jooq.Function1;
import org.jooq.Index;
import org.jooq.Internal;
import org.jooq.Name;
import org.jooq.QueryPart;
// ...
import org.jooq.Schema;
import org.jooq.Sequence;
import org.jooq.Table;
// ...
import org.jooq.UDT;
import org.jooq.UniqueKey;
import org.jooq.QueryPart;
// ...
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A schema that references a lazy initialisable {@link Schema} singleton, for

View File

@ -40,7 +40,7 @@ package org.jooq.impl;
import java.io.Serializable;
import java.util.function.Supplier;
import org.jooq.Internal;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A lazy supplier

View File

@ -37,18 +37,16 @@
*/
package org.jooq.impl;
import java.util.function.BiFunction;
import java.util.function.Predicate;
import org.jooq.Catalog;
import org.jooq.Context;
import org.jooq.Function1;
import org.jooq.Package;
import org.jooq.QueryPart;
// ...
import org.jooq.SQLDialect;
import org.jooq.Schema;
// ...
import org.jooq.QueryPart;
// ...
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A default implementation for packages (containers of stored procedures and
@ -60,7 +58,7 @@ import org.jooq.QueryPart;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class PackageImpl extends AbstractNamed implements Package {
private Schema schema;

View File

@ -49,8 +49,6 @@ import static org.jooq.tools.StringUtils.defaultIfNull;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.function.BiFunction;
import java.util.function.Predicate;
import java.util.stream.Stream;
import org.jooq.Catalog;
@ -59,19 +57,20 @@ import org.jooq.Comment;
import org.jooq.Context;
import org.jooq.Domain;
import org.jooq.ForeignKey;
import org.jooq.Function1;
import org.jooq.Index;
import org.jooq.Name;
import org.jooq.QueryPart;
// ...
import org.jooq.Schema;
import org.jooq.Sequence;
import org.jooq.Table;
// ...
import org.jooq.UDT;
import org.jooq.UniqueKey;
import org.jooq.QueryPart;
// ...
import org.jooq.tools.StringUtils;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A common base class for database schemata
* <p>
@ -79,7 +78,7 @@ import org.jooq.tools.StringUtils;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class SchemaImpl extends AbstractNamed implements Schema {
private static final Clause[] CLAUSES = { SCHEMA, SCHEMA_REFERENCE };

View File

@ -74,12 +74,9 @@ import org.jooq.SQLDialect;
import org.jooq.Schema;
import org.jooq.Select;
import org.jooq.Sequence;
import org.jooq.exception.SQLDialectNotSupportedException;
import org.jooq.impl.QOM.UEmpty;
import org.jooq.impl.QOM.UNotYetImplemented;
import org.jooq.impl.QOM.UTransient;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A common base class for sequences
@ -88,7 +85,7 @@ import org.jetbrains.annotations.Nullable;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class SequenceImpl<T extends Number>
extends
AbstractTypedNamed<T>

View File

@ -62,8 +62,6 @@ import static org.jooq.tools.StringUtils.defaultIfNull;
import java.util.Arrays;
import java.util.Set;
import java.util.function.BiFunction;
import java.util.function.Predicate;
import java.util.stream.Stream;
import org.jooq.Clause;
@ -71,7 +69,6 @@ import org.jooq.Comment;
import org.jooq.Context;
import org.jooq.Field;
import org.jooq.ForeignKey;
import org.jooq.Function1;
import org.jooq.Name;
// ...
import org.jooq.QueryPart;
@ -87,6 +84,8 @@ import org.jooq.TableOptions;
import org.jooq.impl.QOM.UNotYetImplemented;
import org.jooq.tools.StringUtils;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A common base type for tables
* <p>
@ -94,7 +93,7 @@ import org.jooq.tools.StringUtils;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class TableImpl<R extends Record>
extends
AbstractTable<R>
@ -258,7 +257,7 @@ implements
* This method is used by generated code of table valued functions. Do not
* call this method directly.
*/
@org.jooq.Internal
@Internal
protected boolean aliased() {
return getAliasedTable() != null;
}
@ -269,13 +268,13 @@ implements
* This method is used by generated code of synthetic views. Do not
* call this method directly.
*/
@org.jooq.Internal
@Internal
protected boolean isSynthetic() {
return false;
}
@Override
@org.jooq.Internal
@Internal
public final boolean isSimple(Context<?> ctx) {
return alias == null && (parameters == null || parameters.length < 2);
}

View File

@ -39,7 +39,6 @@ package org.jooq.impl;
import static java.lang.Boolean.FALSE;
import static java.lang.Boolean.TRUE;
import static java.util.Arrays.asList;
// ...
import static org.jooq.SQLDialect.DERBY;
import static org.jooq.SQLDialect.H2;
@ -50,13 +49,9 @@ import static org.jooq.SQLDialect.MYSQL;
// ...
import static org.jooq.conf.SettingsTools.updatablePrimaryKeys;
import static org.jooq.conf.WriteIfReadonly.IGNORE;
import static org.jooq.conf.WriteIfReadonly.THROW;
import static org.jooq.conf.WriteIfReadonly.WRITE;
import static org.jooq.impl.RecordDelegate.delegate;
import static org.jooq.impl.RecordDelegate.RecordLifecycleType.INSERT;
import static org.jooq.impl.Tools.EMPTY_FIELD;
import static org.jooq.impl.Tools.collect;
import static org.jooq.impl.Tools.filter;
import static org.jooq.impl.Tools.indexOrFail;
import static org.jooq.impl.Tools.settings;
import static org.jooq.impl.Tools.BooleanDataKey.DATA_OMIT_RETURNING_CLAUSE;
@ -77,9 +72,7 @@ import org.jooq.DataType;
import org.jooq.Field;
import org.jooq.ForeignKey;
import org.jooq.Identity;
import org.jooq.Insert;
import org.jooq.InsertQuery;
// ...
import org.jooq.Record;
import org.jooq.SQLDialect;
import org.jooq.StoreQuery;
@ -88,12 +81,12 @@ import org.jooq.TableField;
import org.jooq.TableRecord;
import org.jooq.UniqueKey;
import org.jooq.UpdatableRecord;
import org.jooq.Update;
import org.jooq.conf.Settings;
import org.jooq.conf.WriteIfReadonly;
import org.jooq.exception.DataTypeException;
import org.jooq.tools.JooqLogger;
import org.jooq.tools.StringUtils;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A record implementation for a record originating from a single table
@ -102,7 +95,7 @@ import org.jooq.tools.StringUtils;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class TableRecordImpl<R extends TableRecord<R>> extends AbstractQualifiedRecord<R> implements TableRecord<R> {
private static final JooqLogger log = JooqLogger.getLogger(TableRecordImpl.class);
private static final Set<SQLDialect> REFRESH_GENERATED_KEYS = SQLDialect.supportedBy(DERBY, H2, MARIADB, MYSQL);

View File

@ -47,17 +47,15 @@ import org.jooq.DataType;
import org.jooq.Name;
import org.jooq.Named;
import org.jooq.Package;
import org.jooq.QueryPart;
import org.jooq.Record;
import org.jooq.Row;
import org.jooq.Schema;
import org.jooq.UDT;
import org.jooq.UDTField;
import org.jooq.UDTRecord;
import org.jooq.QueryPart;
import org.jooq.impl.QOM.UNotYetImplemented;
import org.jetbrains.annotations.Nullable;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A common base type for UDT's
@ -66,7 +64,7 @@ import org.jetbrains.annotations.Nullable;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class UDTImpl<R extends UDTRecord<R>>
extends
AbstractNamed

View File

@ -40,6 +40,8 @@ package org.jooq.impl;
import org.jooq.UDT;
import org.jooq.UDTRecord;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A record implementation for a record originating from a single UDT
* <p>
@ -47,7 +49,7 @@ import org.jooq.UDTRecord;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class UDTRecordImpl<R extends UDTRecord<R>> extends AbstractQualifiedRecord<R> implements UDTRecord<R> {
public UDTRecordImpl(UDT<R> udt) {

View File

@ -89,6 +89,8 @@ import org.jooq.exception.NoDataFoundException;
import org.jooq.tools.JooqLogger;
import org.jooq.tools.StringUtils;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* A record implementation for a record holding a primary key
* <p>
@ -96,7 +98,7 @@ import org.jooq.tools.StringUtils;
*
* @author Lukas Eder
*/
@org.jooq.Internal
@Internal
public class UpdatableRecordImpl<R extends UpdatableRecord<R>> extends TableRecordImpl<R> implements UpdatableRecord<R> {
private static final JooqLogger log = JooqLogger.getLogger(UpdatableRecordImpl.class);
private static final Set<SQLDialect> NO_SUPPORT_FOR_UPDATE = SQLDialect.supportedBy(SQLITE);

View File

@ -64,6 +64,29 @@ import java.util.List;
import java.util.Map;
import javax.xml.XMLConstants;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
import javax.xml.validation.Schema;
import javax.xml.validation.SchemaFactory;
import org.jooq.Constants;
import org.jooq.exception.ConfigurationException;
import org.jooq.tools.Convert;
import org.jooq.tools.JooqLogger;
import org.jooq.tools.reflect.Reflect;
import org.jooq.tools.reflect.ReflectException;
import org.jetbrains.annotations.ApiStatus.Internal;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
import org.xml.sax.ErrorHandler;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
import org.xml.sax.SAXParseException;
import jakarta.xml.bind.annotation.XmlElement;
import jakarta.xml.bind.annotation.XmlElementWrapper;
import jakarta.xml.bind.annotation.XmlEnum;
@ -73,28 +96,6 @@ import jakarta.xml.bind.annotation.XmlSchema;
import jakarta.xml.bind.annotation.XmlType;
import jakarta.xml.bind.annotation.adapters.XmlAdapter;
import jakarta.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
import javax.xml.parsers.ParserConfigurationException;
import javax.xml.validation.Schema;
import javax.xml.validation.SchemaFactory;
import org.jooq.Constants;
import org.jooq.Internal;
import org.jooq.exception.ConfigurationException;
import org.jooq.tools.Convert;
import org.jooq.tools.JooqLogger;
import org.jooq.tools.reflect.Reflect;
import org.jooq.tools.reflect.ReflectException;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
import org.xml.sax.ErrorHandler;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;
import org.xml.sax.SAXParseException;
/**
* This class allows for mashalling / unmarshalling XML content to jOOQ

View File

@ -37,7 +37,7 @@
*/
package org.jooq.util.jaxb.tools;
import org.jooq.Internal;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* Interface to be implemented by JAXB annotated Java classes which are

View File

@ -41,7 +41,7 @@ import java.io.IOException;
import java.util.List;
import java.util.regex.Pattern;
import org.jooq.Internal;
import org.jetbrains.annotations.ApiStatus.Internal;
/**
* Wrapper around a {@link StringBuilder} which can be used to serialize