[jOOQ/jOOQ#13437] Add Definition.isSynthetic() to indicate that a jOOQ-meta object has been created synthetically

This commit is contained in:
Lukas Eder 2022-04-08 14:51:56 +02:00
parent dae57e01cd
commit 3291bc007a

View File

@ -41,6 +41,7 @@ package org.jooq.meta;
import java.util.List;
import org.jooq.Name;
import org.jooq.meta.jaxb.SyntheticObjectsType;
/**
* A general interface defining any database object, such as tables, views,
@ -148,4 +149,13 @@ public interface Definition {
* <code>null</code>, if no such source code is available.
*/
String getSource();
/**
* Whether the object has been created "synthetically", i.e. from
* {@link SyntheticObjectsType}, rather than from the underlying meta data
* source.
*/
default boolean isSynthetic() {
return false;
}
}