diff --git a/build.gradle b/build.gradle index 5e07f3678..4685e45c0 100644 --- a/build.gradle +++ b/build.gradle @@ -64,6 +64,10 @@ allprojects { ':smack-extensions', ':smack-experimental', ].collect{ project(it) } + androidBootClasspathProjects = [ + ':smack-android', + ':smack-android-extensions', + ].collect{ project(it) } androidBootClasspath = getAndroidRuntimeJar() androidJavadocOffline = getAndroidJavadocOffline() junitVersion = '4.11' @@ -114,12 +118,6 @@ allprojects { options.encoding = "utf8" } - if (JavaVersion.current().isJava8Compatible()) { - tasks.withType(Javadoc) { - options.addStringOption('Xdoclint:none', '-quiet') - } - } - jacoco { toolVersion = "0.7.4.201502262128" } @@ -155,9 +153,13 @@ task javadocAll(type: Javadoc) { // Might need a classpath classpath = files(subprojects.collect {project -> project.sourceSets.main.compileClasspath}) + classpath += files(androidBootClasspath) options.linkSource = true options.use = true - options.links = ["http://docs.oracle.com/javase/$sourceCompatibility/docs/api/"] as String[] + options.links = [ + "http://docs.oracle.com/javase/$sourceCompatibility/docs/api/", + "http://jxmpp.org/$jxmppVersion/javadoc/", + ] as String[] } import org.apache.tools.ant.filters.ReplaceTokens @@ -328,6 +330,15 @@ subprojects*.jar { } } +configure(androidBootClasspathProjects) { + compileJava { + options.bootClasspath = androidBootClasspath + } + javadoc { + classpath += files(androidBootClasspath) + } +} + apply plugin: "com.github.kt3k.coveralls" coveralls { sourceDirs = files(subprojects.sourceSets.main.allSource.srcDirs).files.absolutePath diff --git a/smack-android-extensions/build.gradle b/smack-android-extensions/build.gradle index 81e5d83a5..3279bdeb1 100644 --- a/smack-android-extensions/build.gradle +++ b/smack-android-extensions/build.gradle @@ -7,14 +7,3 @@ dependencies { compile project(':smack-android') compile project(':smack-extensions') } - -compileJava { - options.bootClasspath = androidBootClasspath -} - -// See http://stackoverflow.com/a/2823592/194894 -// TODO this doesn't seem to work right now. But on the other hand it -// is not really required, just to avoid a javadoc compiler warning -javadoc { - options.linksOffline "http://developer.android.com/reference", androidJavadocOffline -} \ No newline at end of file diff --git a/smack-android/build.gradle b/smack-android/build.gradle index 48e9a4785..e302aa602 100644 --- a/smack-android/build.gradle +++ b/smack-android/build.gradle @@ -16,17 +16,6 @@ dependencies { } } -compileJava { - options.bootClasspath = androidBootClasspath -} - -// See http://stackoverflow.com/a/2823592/194894 -// TODO this doesn't seem to work right now. But on the other hand it -// is not really required, just to avoid a javadoc compiler warning -javadoc { - options.linksOffline "http://developer.android.com/reference", androidJavadocOffline -} - configure (androidProjects) { task compileAndroid(type: JavaCompile) { source = compileJava.source @@ -36,4 +25,4 @@ configure (androidProjects) { } } -test { dependsOn androidProjects*.compileAndroid } \ No newline at end of file +test { dependsOn androidProjects*.compileAndroid } diff --git a/smack-core/src/main/java/org/jivesoftware/smack/XMPPConnection.java b/smack-core/src/main/java/org/jivesoftware/smack/XMPPConnection.java index 815bb3d53..93ba1ead0 100644 --- a/smack-core/src/main/java/org/jivesoftware/smack/XMPPConnection.java +++ b/smack-core/src/main/java/org/jivesoftware/smack/XMPPConnection.java @@ -32,7 +32,7 @@ import org.jxmpp.jid.FullJid; /** * The XMPPConnection interface provides an interface for connections to an XMPP server and * implements shared methods which are used by the different types of connections (e.g. - * {@link XMPPTCPConnection} or {@link XMPPBOSHConnection}). To create a connection to an XMPP server + * XMPPTCPConnection or XMPPBOSHConnection). To create a connection to an XMPP server * a simple usage of this API might look like the following: *

* @@ -70,7 +70,6 @@ import org.jxmpp.jid.FullJid; * @author Matt Tucker * @author Guenther Niess */ -@SuppressWarnings("javadoc") public interface XMPPConnection { /** diff --git a/smack-im/src/main/java/org/jivesoftware/smack/roster/Roster.java b/smack-im/src/main/java/org/jivesoftware/smack/roster/Roster.java index 59fdaf9e3..3469c78bb 100644 --- a/smack-im/src/main/java/org/jivesoftware/smack/roster/Roster.java +++ b/smack-im/src/main/java/org/jivesoftware/smack/roster/Roster.java @@ -458,7 +458,6 @@ public class Roster extends Manager { * @param name the nickname of the user. * @param groups the list of group names the entry will belong to, or null if the * the roster entry won't belong to a group. - * @param approved the pre-approval state. * @throws NoResponseException if there was no response from the server. * @throws XMPPErrorException if an XMPP exception occurs. * @throws NotLoggedInException If not logged in. @@ -502,7 +501,6 @@ public class Roster extends Manager { * @param name the nickname of the user. * @param groups the list of group names the entry will belong to, or null if the * the roster entry won't belong to a group. - * @param approved the pre-approval state. * @throws NoResponseException if there was no response from the server. * @throws XMPPErrorException if an XMPP exception occurs. * @throws NotLoggedInException if not logged in. diff --git a/smack-legacy/src/main/java/org/jivesoftware/smackx/workgroup/packet/OfferRequestProvider.java b/smack-legacy/src/main/java/org/jivesoftware/smackx/workgroup/packet/OfferRequestProvider.java index 0f99ad1e4..770129b89 100644 --- a/smack-legacy/src/main/java/org/jivesoftware/smackx/workgroup/packet/OfferRequestProvider.java +++ b/smack-legacy/src/main/java/org/jivesoftware/smackx/workgroup/packet/OfferRequestProvider.java @@ -85,13 +85,13 @@ public class OfferRequestProvider extends IQProvider { } else if (RoomInvitation.ELEMENT_NAME.equals(elemName)) { RoomInvitation invitation = (RoomInvitation) PacketParserUtils - .parsePacketExtension(RoomInvitation.ELEMENT_NAME, RoomInvitation.NAMESPACE, parser); + .parseExtensionElement(RoomInvitation.ELEMENT_NAME, RoomInvitation.NAMESPACE, parser); content = new InvitationRequest(invitation.getInviter(), invitation.getRoom(), invitation.getReason()); } else if (RoomTransfer.ELEMENT_NAME.equals(elemName)) { RoomTransfer transfer = (RoomTransfer) PacketParserUtils - .parsePacketExtension(RoomTransfer.ELEMENT_NAME, RoomTransfer.NAMESPACE, parser); + .parseExtensionElement(RoomTransfer.ELEMENT_NAME, RoomTransfer.NAMESPACE, parser); content = new TransferRequest(transfer.getInviter(), transfer.getRoom(), transfer.getReason()); } }