我正在尝试将QueryDSL、Gradle 和 Springboot集成到标题版本中。我向 gradle 添加了 annotationProcessors,但 Intellij 仍然没有生成 QClasses。我尝试了来自社区的建议以使用插件 'gradle.plugin.com.ewerk.gradle.plugins:querydsl-plugin' 但这没有帮助。
dependencies{
annotationProcessor("org.projectlombok:lombok:1.18.4")
annotationProcessor("com.querydsl:querydsl-apt:4.2.1")
annotationProcessor("org.springframework.boot:spring-boot-starter-data-jpa:2.1.1.RELEASE")
compileOnly("org.projectlombok:lombok:1.18.4")
implementation("com.querydsl:querydsl-jpa:4.2.1")
implementation("com.querydsl:querydsl-apt:4.2.1:jpa")
implementation("org.springframework.boot:spring-boot-starter-data-jpa:2.1.1.RELEASE")
implementation("org.springframework.boot:spring-boot-starter-web:2.1.1.RELEASE")
}
Run Code Online (Sandbox Code Playgroud)