[jOOQ/jOOQ#10524] Add DataType.isEmbeddable()
This commit is contained in:
parent
d8eac6cc60
commit
fdc05e3349
@ -770,6 +770,11 @@ public interface DataType<T> extends Named {
|
||||
*/
|
||||
boolean isArray();
|
||||
|
||||
/**
|
||||
* Whether this data type is an embeddable type.
|
||||
*/
|
||||
boolean isEmbeddable();
|
||||
|
||||
/**
|
||||
* Whether this data type is a UDT type.
|
||||
*/
|
||||
|
||||
@ -76,6 +76,7 @@ import org.jooq.Context;
|
||||
import org.jooq.Converter;
|
||||
import org.jooq.DataType;
|
||||
import org.jooq.Domain;
|
||||
import org.jooq.EmbeddableRecord;
|
||||
import org.jooq.EnumType;
|
||||
import org.jooq.Field;
|
||||
import org.jooq.JSON;
|
||||
@ -656,6 +657,11 @@ abstract class AbstractDataType<T> extends AbstractNamed implements DataType<T>
|
||||
(!isBinary() && tType.isArray());
|
||||
}
|
||||
|
||||
@Override
|
||||
public final boolean isEmbeddable() {
|
||||
return EmbeddableRecord.class.isAssignableFrom(tType0());
|
||||
}
|
||||
|
||||
@Override
|
||||
public final boolean isUDT() {
|
||||
return UDTRecord.class.isAssignableFrom(tType0());
|
||||
|
||||
Loading…
Reference in New Issue
Block a user