Skip to content

Fix most Javadoc warnings #1420

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 27, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions auth/src/main/java/com/firebase/ui/auth/AuthUI.java
Original file line number Diff line number Diff line change
Expand Up @@ -660,7 +660,7 @@ public PhoneBuilder setDefaultCountryIso(@NonNull String iso) {
* Sets the country codes available in the country code selector for phone
* authentication. Takes as input a List of both country isos and codes.
* This is not to be called with
* {@link #setBlacklistedCountries(List<String>)}.
* {@link #setBlacklistedCountries(List)}.
* If both are called, an exception will be thrown.
* <p>
* Inputting an e-164 country code (e.g. '+1') will include all countries with
Expand Down Expand Up @@ -696,7 +696,7 @@ public PhoneBuilder setWhitelistedCountries(
* Sets the countries to be removed from the country code selector for phone
* authentication. Takes as input a List of both country isos and codes.
* This is not to be called with
* {@link #setWhitelistedCountries(List<String>)}.
* {@link #setWhitelistedCountries(List)}.
* If both are called, an exception will be thrown.
* <p>
* Inputting an e-164 country code (e.g. '+1') will include all countries with
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
/**
* Fragment that shows a form with an email field and checks for existing accounts with that email.
* <p>
* Host Activities should implement {@link CheckEmailListener}.
* Host Activities should implement {@link CheckEmailFragment.CheckEmailListener}.
*/
@RestrictTo(RestrictTo.Scope.LIBRARY_GROUP)
public class CheckEmailFragment extends FragmentBase implements
Expand Down
28 changes: 14 additions & 14 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import com.android.build.gradle.BaseExtension
import com.android.build.gradle.LibraryExtension
import com.jfrog.bintray.gradle.BintrayExtension
import com.jfrog.bintray.gradle.tasks.RecordingCopyTask
import org.jfrog.gradle.plugin.artifactory.dsl.ArtifactoryPluginConvention
Expand Down Expand Up @@ -32,16 +33,6 @@ allprojects {
mavenLocal()
}

// Skip Javadoc generation for Java 1.8 as it breaks build
if (JavaVersion.current().isJava8Compatible) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🍺 pour one out for one of the oldest hacks in the codebase.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well technically I just moved it down and changed the comment, but sure, I'll take it. 😁

tasks.withType<Javadoc> {
options {
this as StandardJavadocDocletOptions
addStringOption("Xdoclint:none", "-quiet")
}
}
}

if ((group as String).isNotEmpty() && name != "lint" && name != "internal") {
configureAndroid()
configureQuality()
Expand Down Expand Up @@ -138,9 +129,18 @@ fun Project.setupPublishing() {
}

val javadoc = task<Javadoc>("javadoc") {
setSource(project.the<BaseExtension>().sourceSets["main"].java.srcDirs)
classpath += configurations["compile"]
classpath += project.files(project.the<BaseExtension>().bootClasspath)
afterEvaluate {
dependsOn(project.the<LibraryExtension>().libraryVariants.map { it.assemble })

setSource(project.the<BaseExtension>().sourceSets["main"].java.srcDirs)
classpath += files(project.the<BaseExtension>().bootClasspath)
classpath += files(project.the<LibraryExtension>().libraryVariants.map {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some code is just ugly in any language haha

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup 😆

(it.javaCompiler as AbstractCompile).classpath
})
}

// Ignore warnings about incomplete documentation
(options as StandardJavadocDocletOptions).addStringOption("Xdoclint:none", "-quiet")
}

val javadocJar = task<Jar>("javadocJar") {
Expand Down Expand Up @@ -195,7 +195,7 @@ fun Project.setupPublishing() {
}.toTypedArray())
}
} else {
val pomTask = "generatePomFileFor${project.name.capitalize()}LibraryPublication"
val pomTask = "generatePomFileFor${name.capitalize()}LibraryPublication"
task("prepareArtifacts") {
dependsOn(javadocJar, sourcesJar, "assembleRelease", pomTask)
}
Expand Down