无符号类型
适用于 ✅ 开源版 ✅ 专业版 ✅ 企业版
JDBC 和 Java 类型系统不知道任何无符号整数数据类型,但某些数据库知道,最重要的是 MySQL。此标志允许覆盖从无符号到有符号整数的默认映射,并生成 jOOU 类型
这些类型的工作方式与普通的 java.lang.Number
包装器类型一样,只是没有它们的原始版本。配置如下
XML(独立和 Maven)
编程方式
Gradle (Kotlin)
Gradle (Groovy)
Gradle(第三方)
<configuration> <generator> <database> <unsignedTypes>true</unsignedTypes> </database> </generator> </configuration>
有关更多详细信息,请参见 configuration XSD,独立的生成代码,和 maven 代码生成。
new org.jooq.meta.jaxb.Configuration() .withGenerator(new Generator() .withDatabase(new Database() .withUnsignedTypes(true) ) )
有关更多详细信息,请参见 configuration XSD 和 程序化代码生成。
import org.jooq.meta.jaxb.* configuration { generator { database { isUnsignedTypes = true } } }
有关更多详细信息,请参见 configuration XSD 和 gradle 代码生成。
configuration { generator { database { unsignedTypes = true } } }
有关更多详细信息,请参见 configuration XSD 和 gradle 代码生成。
// The jOOQ-codegen-gradle plugin has been introduced in version 3.19. // Please use the official plugin instead of the third party plugin that was recommended before.
反馈
您对此页面有任何反馈吗?我们很乐意听取您的意见!