From 08563191e0d1fad641d95826b774fb4815749170 Mon Sep 17 00:00:00 2001 From: asjervanasten Date: Fri, 13 Oct 2023 23:06:43 +0200 Subject: [PATCH 1/3] Adds javadoc return values where missing --- .../gradle/extension/QuarkusPluginExtension.java | 3 +++ .../java/io/quarkus/gradle/tasks/QuarkusDev.java | 15 ++++++++++++--- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/extension/QuarkusPluginExtension.java b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/extension/QuarkusPluginExtension.java index a8d7fbcd40be5..6f7df0aad8e79 100644 --- a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/extension/QuarkusPluginExtension.java +++ b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/extension/QuarkusPluginExtension.java @@ -204,6 +204,9 @@ public void codeGenForkOptions(Action action) { /** * Returns the last file from the specified {@link FileCollection}. + * + * @param fileCollection the collection of files present in the directory + * @return result returns the last file */ public static File getLastFile(FileCollection fileCollection) { File result = null; diff --git a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java index 087cfe11dd965..4b8ceaf312b60 100644 --- a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java +++ b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java @@ -142,6 +142,8 @@ public QuarkusDev( /** * The dependency Configuration associated with this task. Used * for up-to-date checks + * + * @return quarkusDevConfiguration returns the configuration */ @SuppressWarnings("unused") @CompileClasspath @@ -151,6 +153,8 @@ public Configuration getQuarkusDevConfiguration() { /** * The JVM sources (Java, Kotlin, ..) for the project + * + * @return the FileCollection of all java source files present in the source directories */ @Optional @InputFiles @@ -161,6 +165,8 @@ public FileCollection getSources() { /** * The JVM classes directory (compilation output) + * + * @return the FileCollection of all java source files present in the source directories */ @Optional @InputFiles @@ -171,9 +177,11 @@ public FileCollection getCompilationOutput() { /** * The directory to be used as the working dir for the dev process. - * + *

* Defaults to the main source set's classes directory. If there are * multiple, one is picked at random (see {@link QuarkusPluginExtension#getLastFile}). + * + * @return workingDirectory */ @Input public Property getWorkingDirectory() { @@ -204,6 +212,7 @@ public Property getPreventNoVerify() { } /** + * @return boolean value of getPreventNoVerify() * @deprecated see {@link #getPreventNoVerify()} */ @SuppressWarnings("SpellCheckingInspection") @@ -596,7 +605,7 @@ private void addQuarkusDevModeDeps(GradleDevModeLauncher.Builder builder, Applic } private void addLocalProject(ResolvedDependency project, GradleDevModeLauncher.Builder builder, Set addeDeps, - boolean root) { + boolean root) { addeDeps.add(project.getKey()); final ArtifactSources sources = project.getSources(); @@ -676,7 +685,7 @@ private void addLocalProject(ResolvedDependency project, GradleDevModeLauncher.B } Path testClassesDir = testClassesDirs.isEmpty() ? null : QuarkusGradleUtils.mergeClassesDirs(testClassesDirs, project.getWorkspaceModule().getBuildDir(), root, - root); + root); final Set testResourcesSrcDirs = new LinkedHashSet<>(); // resourcesSrcDir may exist but if it's empty the resources output dir won't be created From ca70f9cbfe179d52a27577965c1b665fcc5c9ba9 Mon Sep 17 00:00:00 2001 From: asjervanasten Date: Sat, 14 Oct 2023 00:05:45 +0200 Subject: [PATCH 2/3] Formatted code --- .../src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java index 4b8ceaf312b60..cfaa5b2485d91 100644 --- a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java +++ b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java @@ -605,7 +605,7 @@ private void addQuarkusDevModeDeps(GradleDevModeLauncher.Builder builder, Applic } private void addLocalProject(ResolvedDependency project, GradleDevModeLauncher.Builder builder, Set addeDeps, - boolean root) { + boolean root) { addeDeps.add(project.getKey()); final ArtifactSources sources = project.getSources(); @@ -685,7 +685,7 @@ private void addLocalProject(ResolvedDependency project, GradleDevModeLauncher.B } Path testClassesDir = testClassesDirs.isEmpty() ? null : QuarkusGradleUtils.mergeClassesDirs(testClassesDirs, project.getWorkspaceModule().getBuildDir(), root, - root); + root); final Set testResourcesSrcDirs = new LinkedHashSet<>(); // resourcesSrcDir may exist but if it's empty the resources output dir won't be created From 901734729d05f4e7abdfe633227ecefaa3e3ec45 Mon Sep 17 00:00:00 2001 From: asjervanasten Date: Fri, 13 Oct 2023 23:06:43 +0200 Subject: [PATCH 3/3] Formatted code Adds javadoc return values where missing --- .../gradle/extension/QuarkusPluginExtension.java | 3 +++ .../main/java/io/quarkus/gradle/tasks/QuarkusDev.java | 11 ++++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/extension/QuarkusPluginExtension.java b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/extension/QuarkusPluginExtension.java index a8d7fbcd40be5..6f7df0aad8e79 100644 --- a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/extension/QuarkusPluginExtension.java +++ b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/extension/QuarkusPluginExtension.java @@ -204,6 +204,9 @@ public void codeGenForkOptions(Action action) { /** * Returns the last file from the specified {@link FileCollection}. + * + * @param fileCollection the collection of files present in the directory + * @return result returns the last file */ public static File getLastFile(FileCollection fileCollection) { File result = null; diff --git a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java index 087cfe11dd965..cfaa5b2485d91 100644 --- a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java +++ b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java @@ -142,6 +142,8 @@ public QuarkusDev( /** * The dependency Configuration associated with this task. Used * for up-to-date checks + * + * @return quarkusDevConfiguration returns the configuration */ @SuppressWarnings("unused") @CompileClasspath @@ -151,6 +153,8 @@ public Configuration getQuarkusDevConfiguration() { /** * The JVM sources (Java, Kotlin, ..) for the project + * + * @return the FileCollection of all java source files present in the source directories */ @Optional @InputFiles @@ -161,6 +165,8 @@ public FileCollection getSources() { /** * The JVM classes directory (compilation output) + * + * @return the FileCollection of all java source files present in the source directories */ @Optional @InputFiles @@ -171,9 +177,11 @@ public FileCollection getCompilationOutput() { /** * The directory to be used as the working dir for the dev process. - * + *

* Defaults to the main source set's classes directory. If there are * multiple, one is picked at random (see {@link QuarkusPluginExtension#getLastFile}). + * + * @return workingDirectory */ @Input public Property getWorkingDirectory() { @@ -204,6 +212,7 @@ public Property getPreventNoVerify() { } /** + * @return boolean value of getPreventNoVerify() * @deprecated see {@link #getPreventNoVerify()} */ @SuppressWarnings("SpellCheckingInspection")