From 7f3209fdc06ad09223047a115b3bce5400599229 Mon Sep 17 00:00:00 2001 From: Owen Gray Date: Tue, 24 Mar 2020 18:21:42 -0400 Subject: Fix @see tags Thanks to Jeff for initial solution Fixes: b/142676098 Bug: 142676098 Test: gw test Change-Id: If92fa2df0ea40061f2f0a6b6f16a45897001b62f Merged-In: If92fa2df0ea40061f2f0a6b6f16a45897001b62f --- core/src/main/kotlin/Formats/DacHtmlFormat.kt | 22 ++++++++++++++++++---- .../JavaLayoutHtmlFormatOutputBuilder.kt | 2 +- core/testdata/format/dac/javaSeeTag/Bar.kt | 1 + core/testdata/format/dac/javaSeeTag/Foo.java | 1 + .../format/dac/javaSeeTag/dac-as-java/Bar.html | 5 ++--- core/testdata/format/dac/javaSeeTag/dac/Bar.html | 5 ++--- core/testdata/format/dac/javaSeeTag/dac/Foo.html | 1 + 7 files changed, 26 insertions(+), 11 deletions(-) diff --git a/core/src/main/kotlin/Formats/DacHtmlFormat.kt b/core/src/main/kotlin/Formats/DacHtmlFormat.kt index 6b42dad19..b767c7d6f 100644 --- a/core/src/main/kotlin/Formats/DacHtmlFormat.kt +++ b/core/src/main/kotlin/Formats/DacHtmlFormat.kt @@ -176,11 +176,25 @@ class DevsiteLayoutHtmlFormatOutputBuilder( } } ul(classes = "nolist") { - sections.forEach { - li { - code { - metaMarkup(it.children) + sections.filter {it.tag == "See Also"}.forEach { + it.children.forEach { child -> + if (child is ContentNodeLazyLink || child is ContentExternalLink) { + li { + code { + contentNodeToMarkup(child) // Wrap bare links in listItems. + } // bare links come from the java-to-kotlin parser. + } } + else if (child is ContentUnorderedList) { + metaMarkup(child.children) // Already wrapped in listItems. + } // this is how we want things to look. No parser currently does this (yet). + else if (child is ContentParagraph) { + li{ + code { + metaMarkup (child.children) // Replace paragraphs with listItems. + } // paragraph-wrapped links come from the kotlin parser + } + } // NOTE: currently the java-to-java parser does not add See Also links! } } } diff --git a/core/src/main/kotlin/Formats/JavaLayoutHtml/JavaLayoutHtmlFormatOutputBuilder.kt b/core/src/main/kotlin/Formats/JavaLayoutHtml/JavaLayoutHtmlFormatOutputBuilder.kt index 7fbdb1819..ccea82eae 100644 --- a/core/src/main/kotlin/Formats/JavaLayoutHtml/JavaLayoutHtmlFormatOutputBuilder.kt +++ b/core/src/main/kotlin/Formats/JavaLayoutHtml/JavaLayoutHtmlFormatOutputBuilder.kt @@ -51,7 +51,7 @@ open class JavaLayoutHtmlFormatOutputBuilder( protected fun FlowContent.contentNodesToMarkup(content: List, contextUri: URI = uri): Unit = content.forEach { contentNodeToMarkup(it, contextUri) } - private fun FlowContent.contentNodeToMarkup(content: ContentNode, contextUri: URI) { + protected fun FlowContent.contentNodeToMarkup(content: ContentNode, contextUri: URI = uri) { when (content) { is ContentText -> +content.text is ContentSymbol -> span("symbol") { +content.text } diff --git a/core/testdata/format/dac/javaSeeTag/Bar.kt b/core/testdata/format/dac/javaSeeTag/Bar.kt index 9df671194..21170d363 100644 --- a/core/testdata/format/dac/javaSeeTag/Bar.kt +++ b/core/testdata/format/dac/javaSeeTag/Bar.kt @@ -1,4 +1,5 @@ /** * @see Foo + * @see java.lang.String */ class Bar \ No newline at end of file diff --git a/core/testdata/format/dac/javaSeeTag/Foo.java b/core/testdata/format/dac/javaSeeTag/Foo.java index 94a24606d..b784ae225 100644 --- a/core/testdata/format/dac/javaSeeTag/Foo.java +++ b/core/testdata/format/dac/javaSeeTag/Foo.java @@ -1,5 +1,6 @@ /** * @see #bar + * @see java.lang.String */ public class Foo { public void bar() {} diff --git a/core/testdata/format/dac/javaSeeTag/dac-as-java/Bar.html b/core/testdata/format/dac/javaSeeTag/dac-as-java/Bar.html index 3dbc813fa..663d14727 100644 --- a/core/testdata/format/dac/javaSeeTag/dac-as-java/Bar.html +++ b/core/testdata/format/dac/javaSeeTag/dac-as-java/Bar.html @@ -39,9 +39,8 @@

See Also

diff --git a/core/testdata/format/dac/javaSeeTag/dac/Bar.html b/core/testdata/format/dac/javaSeeTag/dac/Bar.html index b7d8304d3..c49e6d808 100644 --- a/core/testdata/format/dac/javaSeeTag/dac/Bar.html +++ b/core/testdata/format/dac/javaSeeTag/dac/Bar.html @@ -39,9 +39,8 @@

See Also

diff --git a/core/testdata/format/dac/javaSeeTag/dac/Foo.html b/core/testdata/format/dac/javaSeeTag/dac/Foo.html index 473fd2cc2..14a913c99 100644 --- a/core/testdata/format/dac/javaSeeTag/dac/Foo.html +++ b/core/testdata/format/dac/javaSeeTag/dac/Foo.html @@ -58,6 +58,7 @@

See Also

-- cgit v1.2.3 From 28c97a26336a1feb47a59d28e4db94408879433d Mon Sep 17 00:00:00 2001 From: Owen Gray Date: Tue, 7 Apr 2020 09:18:30 -0400 Subject: Fix formatting for deprecation warnings, and add a test. Doesn't fix replacement links. Bug: 149580603 Test: new test (gw test) Change-Id: Ic167dd3e14a1e444985a61a941b3c46b93d521f5 Merged-In: Ic167dd3e14a1e444985a61a941b3c46b93d521f5 --- .../JavaLayoutHtmlFormatOutputBuilder.kt | 4 +- core/src/main/kotlin/Model/Content.kt | 2 +- core/src/test/kotlin/format/DacFormatTest.kt | 4 + .../format/dac/deprecation/DeprecatedBar.kt | 17 ++++ .../format/dac/deprecation/DeprecatedFoo.java | 21 +++++ .../format/dac/deprecation/dac-as-java/Bar.html | 90 ++++++++++++++++++++++ .../dac/deprecation/dac-as-java/DeprecatedBar.html | 41 ++++++++++ .../dac/deprecation/dac-as-java/DeprecatedFoo.html | 41 ++++++++++ .../format/dac/deprecation/dac-as-java/Foo.html | 90 ++++++++++++++++++++++ core/testdata/format/dac/deprecation/dac/Bar.html | 90 ++++++++++++++++++++++ .../format/dac/deprecation/dac/DeprecatedBar.html | 41 ++++++++++ .../format/dac/deprecation/dac/DeprecatedFoo.html | 41 ++++++++++ core/testdata/format/dac/deprecation/dac/Foo.html | 90 ++++++++++++++++++++++ 13 files changed, 569 insertions(+), 3 deletions(-) create mode 100644 core/testdata/format/dac/deprecation/DeprecatedBar.kt create mode 100644 core/testdata/format/dac/deprecation/DeprecatedFoo.java create mode 100644 core/testdata/format/dac/deprecation/dac-as-java/Bar.html create mode 100644 core/testdata/format/dac/deprecation/dac-as-java/DeprecatedBar.html create mode 100644 core/testdata/format/dac/deprecation/dac-as-java/DeprecatedFoo.html create mode 100644 core/testdata/format/dac/deprecation/dac-as-java/Foo.html create mode 100644 core/testdata/format/dac/deprecation/dac/Bar.html create mode 100644 core/testdata/format/dac/deprecation/dac/DeprecatedBar.html create mode 100644 core/testdata/format/dac/deprecation/dac/DeprecatedFoo.html create mode 100644 core/testdata/format/dac/deprecation/dac/Foo.html diff --git a/core/src/main/kotlin/Formats/JavaLayoutHtml/JavaLayoutHtmlFormatOutputBuilder.kt b/core/src/main/kotlin/Formats/JavaLayoutHtml/JavaLayoutHtmlFormatOutputBuilder.kt index ccea82eae..23cb81a1a 100644 --- a/core/src/main/kotlin/Formats/JavaLayoutHtml/JavaLayoutHtmlFormatOutputBuilder.kt +++ b/core/src/main/kotlin/Formats/JavaLayoutHtml/JavaLayoutHtmlFormatOutputBuilder.kt @@ -136,7 +136,7 @@ open class JavaLayoutHtmlFormatOutputBuilder( } ContentHardLineBreak -> br - is ContentParagraph -> p { contentNodesToMarkup(content.children, contextUri) } + is ContentParagraph -> p(classes = content.label) { contentNodesToMarkup(content.children, contextUri) } is NodeRenderContent -> renderedSignature(content.node, mode = content.mode) is ContentNodeLink -> { @@ -884,7 +884,7 @@ open class JavaLayoutHtmlFormatOutputBuilder( emphasis: Boolean = true): ContentNode? { val deprecated = node.deprecation deprecated?.let { - return ContentParagraph().apply { + return ContentParagraph("caution").apply { if (prefix) { append(ContentStrong().apply { text( if (deprecated.content.children.size == 0) "Deprecated." diff --git a/core/src/main/kotlin/Model/Content.kt b/core/src/main/kotlin/Model/Content.kt index f239da7f9..a4c78fabf 100644 --- a/core/src/main/kotlin/Model/Content.kt +++ b/core/src/main/kotlin/Model/Content.kt @@ -106,7 +106,7 @@ object ContentIndentedSoftLineBreak: ContentNode { } class ScriptBlock(val type: String?, val src: String) : ContentBlock() -class ContentParagraph() : ContentBlock() +class ContentParagraph(val label: String? = null) : ContentBlock() class ContentEmphasis() : ContentBlock() class ContentStrong() : ContentBlock() class ContentStrikethrough() : ContentBlock() diff --git a/core/src/test/kotlin/format/DacFormatTest.kt b/core/src/test/kotlin/format/DacFormatTest.kt index ae17420d4..5d8babc3d 100644 --- a/core/src/test/kotlin/format/DacFormatTest.kt +++ b/core/src/test/kotlin/format/DacFormatTest.kt @@ -51,4 +51,8 @@ class DacFormatTest: DacFormatTestCase() { @Test fun javaClassLinks() { verifyBothFormats("javaClassLinks") } + + @Test fun deprecation() { + verifyBothFormats("deprecation") + } } \ No newline at end of file diff --git a/core/testdata/format/dac/deprecation/DeprecatedBar.kt b/core/testdata/format/dac/deprecation/DeprecatedBar.kt new file mode 100644 index 000000000..8eb729299 --- /dev/null +++ b/core/testdata/format/dac/deprecation/DeprecatedBar.kt @@ -0,0 +1,17 @@ +class Bar { + fun replacementBarMethod(): Bar { return Bar() } + + fun badBarMethod(): DeprecatedBar { return DeprecatedBar() } + + /** + * @deprecated Use {@link #replacementBarMethod()} instead. + */ + @Deprecated + fun goodBarMethod(): DeprecatedBar { return DeprecatedBar() } +} + +/** + * @deprecated Use {@link #Bar} instead. + */ +@Deprecated +class DeprecatedBar \ No newline at end of file diff --git a/core/testdata/format/dac/deprecation/DeprecatedFoo.java b/core/testdata/format/dac/deprecation/DeprecatedFoo.java new file mode 100644 index 000000000..3c9c360ee --- /dev/null +++ b/core/testdata/format/dac/deprecation/DeprecatedFoo.java @@ -0,0 +1,21 @@ +public class Foo { + public Foo() { } + + public static Foo replacementFooMethod() { return Foo() } + + public static DeprecatedFoo badFooMethod() { return new DeprecatedFoo() } + + /** + * @deprecated Use {@link #replacementFooMethod()} instead. + */ + @Deprecated + public static DeprecatedFoo goodFooMethod() { return new DeprecatedFoo() } +} + +/** + * @deprecated Use {@link #Foo} instead. + */ +@Deprecated +public class DeprecatedFoo { + public DeprecatedFoo() { } +} diff --git a/core/testdata/format/dac/deprecation/dac-as-java/Bar.html b/core/testdata/format/dac/deprecation/dac-as-java/Bar.html new file mode 100644 index 000000000..483929564 --- /dev/null +++ b/core/testdata/format/dac/deprecation/dac-as-java/Bar.html @@ -0,0 +1,90 @@ + + + Bar +{% setvar book_path %}/_book.yaml{% endsetvar %} +{% include "_shared/_reference-head-tags.html" %} + + +
+

Bar

+
public final class Bar implements java.lang.Object
+ + + + +
Bar
+

Summary

+ + + + + + + + + +
+ +

Public constructors

+
+
+
Bar()
+

+
+ + + + + + + + + + + + + + + + + + +
+ +

Public methods

+
+
final DeprecatedBar + +

+
final DeprecatedBar + +

+
final Bar + +

+
+

Public constructors

+ +
+

Bar

+
public Bar()
+
+

Public methods

+ +
+

badBarMethod

+
public final DeprecatedBar badBarMethod()
+
+ +
+

goodBarMethod

+
public final DeprecatedBar goodBarMethod()
+

Deprecated: Deprecated

+
+ +
+

replacementBarMethod

+
public final Bar replacementBarMethod()
+
+ + diff --git a/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedBar.html b/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedBar.html new file mode 100644 index 000000000..71da6a1e8 --- /dev/null +++ b/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedBar.html @@ -0,0 +1,41 @@ + + + DeprecatedBar +{% setvar book_path %}/_book.yaml{% endsetvar %} +{% include "_shared/_reference-head-tags.html" %} + + +
+

DeprecatedBar

+
public final class DeprecatedBar implements java.lang.Object
+ + + + +
DeprecatedBar
+

Summary

+ + + + + + + + + +
+ +

Public constructors

+
+
+ +

+
+

Public constructors

+ +
+

DeprecatedBar

+
public DeprecatedBar()
+
+ + diff --git a/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedFoo.html b/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedFoo.html new file mode 100644 index 000000000..8cf0c575d --- /dev/null +++ b/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedFoo.html @@ -0,0 +1,41 @@ + + + DeprecatedFoo +{% setvar book_path %}/_book.yaml{% endsetvar %} +{% include "_shared/_reference-head-tags.html" %} + + +
+

DeprecatedFoo

+
public class DeprecatedFoo implements java.lang.Object
+ + + + +
DeprecatedFoo
+

Summary

+ + + + + + + + + +
+ +

Public constructors

+
+
+ +

+
+

Public constructors

+ +
+

DeprecatedFoo

+
public DeprecatedFoo()
+
+ + diff --git a/core/testdata/format/dac/deprecation/dac-as-java/Foo.html b/core/testdata/format/dac/deprecation/dac-as-java/Foo.html new file mode 100644 index 000000000..b07ac3cc9 --- /dev/null +++ b/core/testdata/format/dac/deprecation/dac-as-java/Foo.html @@ -0,0 +1,90 @@ + + + Foo +{% setvar book_path %}/_book.yaml{% endsetvar %} +{% include "_shared/_reference-head-tags.html" %} + + +
+

Foo

+
public class Foo implements java.lang.Object
+ + + + +
Foo
+

Summary

+ + + + + + + + + +
+ +

Public constructors

+
+
+
Foo()
+

+
+ + + + + + + + + + + + + + + + + + +
+ +

Public methods

+
+
static DeprecatedFoo + +

+
static DeprecatedFoo + +

+
static Foo + +

+
+

Public constructors

+ +
+

Foo

+
public Foo()
+
+

Public methods

+ +
+

badFooMethod

+
public static DeprecatedFoo badFooMethod()
+
+ +
+

goodFooMethod

+
public static DeprecatedFoo goodFooMethod()
+

Deprecated.

+
+ +
+

replacementFooMethod

+
public static Foo replacementFooMethod()
+
+ + diff --git a/core/testdata/format/dac/deprecation/dac/Bar.html b/core/testdata/format/dac/deprecation/dac/Bar.html new file mode 100644 index 000000000..8b3e6c3fc --- /dev/null +++ b/core/testdata/format/dac/deprecation/dac/Bar.html @@ -0,0 +1,90 @@ + + + Bar +{% setvar book_path %}/_book.yaml{% endsetvar %} +{% include "_shared/_reference-head-tags.html" %} + + +
+

Bar

+
class Bar
+ + + + +
Bar
+

Summary

+ + + + + + + + + +
+ +

Public constructors

+
+
+ +

+
+ + + + + + + + + + + + + + + + + + +
+ +

Public methods

+
+
DeprecatedBar + +

+
DeprecatedBar + +

+
Bar + +

+
+

Public constructors

+ +
+

<init>

+
Bar()
+
+

Public methods

+ +
+

badBarMethod

+
fun badBarMethod(): DeprecatedBar
+
+ +
+

goodBarMethod

+
fun goodBarMethod(): DeprecatedBar
+

Deprecated.

+
+ +
+

replacementBarMethod

+
fun replacementBarMethod(): Bar
+
+ + diff --git a/core/testdata/format/dac/deprecation/dac/DeprecatedBar.html b/core/testdata/format/dac/deprecation/dac/DeprecatedBar.html new file mode 100644 index 000000000..09758f061 --- /dev/null +++ b/core/testdata/format/dac/deprecation/dac/DeprecatedBar.html @@ -0,0 +1,41 @@ + + + DeprecatedBar +{% setvar book_path %}/_book.yaml{% endsetvar %} +{% include "_shared/_reference-head-tags.html" %} + + +
+

DeprecatedBar

+
class DeprecatedBar
+ + + + +
DeprecatedBar
+

Summary

+ + + + + + + + + +
+ +

Public constructors

+
+
+ +

+
+

Public constructors

+ +
+

<init>

+
DeprecatedBar()
+
+ + diff --git a/core/testdata/format/dac/deprecation/dac/DeprecatedFoo.html b/core/testdata/format/dac/deprecation/dac/DeprecatedFoo.html new file mode 100644 index 000000000..16974894f --- /dev/null +++ b/core/testdata/format/dac/deprecation/dac/DeprecatedFoo.html @@ -0,0 +1,41 @@ + + + DeprecatedFoo +{% setvar book_path %}/_book.yaml{% endsetvar %} +{% include "_shared/_reference-head-tags.html" %} + + +
+

DeprecatedFoo

+
open class DeprecatedFoo
+ + + + +
DeprecatedFoo
+

Summary

+ + + + + + + + + +
+ +

Public constructors

+
+
+ +

+
+

Public constructors

+ +
+

<init>

+
DeprecatedFoo()
+
+ + diff --git a/core/testdata/format/dac/deprecation/dac/Foo.html b/core/testdata/format/dac/deprecation/dac/Foo.html new file mode 100644 index 000000000..7dcc84289 --- /dev/null +++ b/core/testdata/format/dac/deprecation/dac/Foo.html @@ -0,0 +1,90 @@ + + + Foo +{% setvar book_path %}/_book.yaml{% endsetvar %} +{% include "_shared/_reference-head-tags.html" %} + + +
+

Foo

+
open class Foo
+ + + + +
Foo
+

Summary

+ + + + + + + + + +
+ +

Public constructors

+
+
+ +

+
+ + + + + + + + + + + + + + + + + + +
+ +

Public methods

+
+
open static DeprecatedFoo! + +

+
open static DeprecatedFoo! + +

+
open static Foo! + +

+
+

Public constructors

+ +
+

<init>

+
Foo()
+
+

Public methods

+ +
+

badFooMethod

+
open static fun badFooMethod(): DeprecatedFoo!
+
+ +
+

goodFooMethod

+
open static fun goodFooMethod(): DeprecatedFoo!
+

Deprecated: Use replacementFooMethod() instead.

+
+ +
+

replacementFooMethod

+
open static fun replacementFooMethod(): Foo!
+
+ + -- cgit v1.2.3 From 796ec8aca01e6e8fad5a4208bfa8a1907123baba Mon Sep 17 00:00:00 2001 From: Andrea Falcone Date: Tue, 7 Apr 2020 21:42:09 -0400 Subject: Revert racy code and test for inherited methods Until a more appropriate solution is found Bug: 157048140 Test: ./gradlew core:test Change-Id: I0f9d50072a422ae0b34cadd9b1517a04a51ff5ca Merged-In: I0f9d50072a422ae0b34cadd9b1517a04a51ff5ca --- .../kotlin/Java/JavaPsiDocumentationBuilder.kt | 14 +---------- .../dac/inheritedMethods/dac-as-java/Child.html | 29 ---------------------- 2 files changed, 1 insertion(+), 42 deletions(-) diff --git a/core/src/main/kotlin/Java/JavaPsiDocumentationBuilder.kt b/core/src/main/kotlin/Java/JavaPsiDocumentationBuilder.kt index 8776da4c2..ed4d36687 100644 --- a/core/src/main/kotlin/Java/JavaPsiDocumentationBuilder.kt +++ b/core/src/main/kotlin/Java/JavaPsiDocumentationBuilder.kt @@ -209,20 +209,8 @@ class JavaPsiDocumentationBuilder : JavaDocumentationBuilder { superTypes.filter { !ignoreSupertype(it) }.forEach { superType -> node.appendType(superType, NodeKind.Supertype) val superClass = superType.resolve() - // parentNode is the actual DocumentationNode of this class's supertype - // It is necessary to create documentation links back to the superclass from inherited methods - val parentNode = refGraph.lookup(superType.typeSignature()) - if (superClass != null && parentNode != null) { + if (superClass != null) { link(superClass, node, RefKind.Inheritor) - // Explicitly add the methods of the superclass (which are not overridden) as nodes to this class - val overriddenMethods = methods.toList().flatMap { it.findSuperMethods().toList() } - val inheritedMethods = superClass.methods.filter { it !in overriddenMethods }.toTypedArray() - - node.appendChildren(inheritedMethods, RefKind.InheritedMember) { - val child = build() - child.addReferenceTo(parentNode, RefKind.Owner) - return@appendChildren child - } } } diff --git a/core/testdata/format/dac/inheritedMethods/dac-as-java/Child.html b/core/testdata/format/dac/inheritedMethods/dac-as-java/Child.html index 65e2addb0..a66d0bf6c 100644 --- a/core/testdata/format/dac/inheritedMethods/dac-as-java/Child.html +++ b/core/testdata/format/dac/inheritedMethods/dac-as-java/Child.html @@ -60,35 +60,6 @@ - - - - - - - - - -
- -

Inherited functions

-
-
- -

Public constructors

-- cgit v1.2.3 From 17d477365e5a556d705e24dd3a1f8558af46582a Mon Sep 17 00:00:00 2001 From: Owen Gray Date: Tue, 7 Apr 2020 20:21:00 -0400 Subject: Rev version to g010 Bug: 157048140 Test: N/A Change-Id: I9a2770b11dc82d3d30660ac4625053ab12b6aff6 Merged-In: I9a2770b11dc82d3d30660ac4625053ab12b6aff6 --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 4c10991b5..79056aa4c 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,4 @@ -dokka_version=0.9.17-g009 +dokka_version=0.9.17-g010 dokka_publication_channel=dokka #Kotlin compiler and plugin -- cgit v1.2.3 From 67f093a6ea786c4337053ba21f9963c906c07a13 Mon Sep 17 00:00:00 2001 From: Rahul Ravikumar Date: Thu, 16 Apr 2020 14:21:27 -0700 Subject: Add a build target for Dokka which makes the repository available. * This makes it easier to expose Dokka as an artifact. Test: N/A (cherry pick from AOSP master) Bug: 157048140 Change-Id: Ic1b4435957064d7b12b8fd8edc0a3e53ab3cba58 Merged-In: Ic1b4435957064d7b12b8fd8edc0a3e53ab3cba58 --- busytown.gradle | 14 +++++++++++--- busytown.sh | 2 +- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/busytown.gradle b/busytown.gradle index f16d8539a..1b9a7119f 100644 --- a/busytown.gradle +++ b/busytown.gradle @@ -23,8 +23,16 @@ allprojects { project -> destinationDir destDir archiveName = "maven.zip" } - zipMaven.dependsOn(":runners:android-gradle-plugin:publishToDistMaven") - zipMaven.dependsOn(":runners:gradle-plugin:publishToDistMaven") - zipMaven.dependsOn(":runners:fatjar:publishToDistMaven") + + def copyRepository = project.tasks.create("copyRepository", Copy) { + from file("${project.buildDir}/dist-maven") + into "${destDir}/repository" + } + + [copyRepository, zipMaven].forEach { + it.dependsOn(":runners:android-gradle-plugin:publishToDistMaven") + it.dependsOn(":runners:gradle-plugin:publishToDistMaven") + it.dependsOn(":runners:fatjar:publishToDistMaven") + } } } diff --git a/busytown.sh b/busytown.sh index d99bdfe91..ca1ae6199 100755 --- a/busytown.sh +++ b/busytown.sh @@ -3,4 +3,4 @@ set -e SCRIPT_DIR="$(cd $(dirname $0) && pwd)" -"$SCRIPT_DIR"/gradlew -p "$SCRIPT_DIR" -I "$SCRIPT_DIR"/busytown.gradle --no-daemon :core:build :runners:android-gradle-plugin:build :runners:gradle-integration-tests:build zipMaven \ No newline at end of file +"$SCRIPT_DIR"/gradlew -p "$SCRIPT_DIR" -I "$SCRIPT_DIR"/busytown.gradle --no-daemon :core:build :runners:android-gradle-plugin:build :runners:gradle-integration-tests:build zipMaven copyRepository \ No newline at end of file -- cgit v1.2.3 From 974537be9dbf4a097bb6408fd87702962b8bf77e Mon Sep 17 00:00:00 2001 From: Bob Badour Date: Thu, 23 Apr 2020 13:47:03 -0700 Subject: Add license type: Apache2 is a NOTICE license Bug: 68860345 Bug: 69058154 Bug: 151953481 Test: no code changes Change-Id: I451517d79090d5be4782b31fcf74e77186bd300f Merged-In: I451517d79090d5be4782b31fcf74e77186bd300f --- METADATA | 1 + 1 file changed, 1 insertion(+) diff --git a/METADATA b/METADATA index 8b9dd3b90..dfb86523a 100644 --- a/METADATA +++ b/METADATA @@ -7,6 +7,7 @@ third_party { type: GIT value: "https://github.com/Kotlin/dokka.git" } + license_type: NOTICE last_upgrade_date { year: 2019 month: 7 -- cgit v1.2.3 From d0fc7c33eec8d3221248a5734b08aad15d9bdf94 Mon Sep 17 00:00:00 2001 From: Tiem Song Date: Wed, 6 May 2020 13:24:47 -0700 Subject: Remove deprecated devsite-heading tag Bug: 154722067 Test: ./gradlew :core:test Change-Id: Id330fb0fb802c91020b345ed6aa50e3a39707e3a Merged-In: Id330fb0fb802c91020b345ed6aa50e3a39707e3a --- core/src/main/kotlin/Formats/DacHtmlFormat.kt | 26 +++------------------- .../format/dac/deprecation/dac-as-java/Bar.html | 12 ++-------- .../dac/deprecation/dac-as-java/DeprecatedBar.html | 6 +---- .../dac/deprecation/dac-as-java/DeprecatedFoo.html | 6 +---- .../format/dac/deprecation/dac-as-java/Foo.html | 12 ++-------- core/testdata/format/dac/deprecation/dac/Bar.html | 12 ++-------- .../format/dac/deprecation/dac/DeprecatedBar.html | 6 +---- .../format/dac/deprecation/dac/DeprecatedFoo.html | 6 +---- core/testdata/format/dac/deprecation/dac/Foo.html | 12 ++-------- .../dac/inheritedMethods/dac-as-java/Child.html | 12 ++-------- .../dac/inheritedMethods/dac-as-java/Parent.html | 12 ++-------- .../format/dac/inheritedMethods/dac/Child.html | 18 +++------------ .../format/dac/inheritedMethods/dac/Parent.html | 12 ++-------- .../format/dac/javaClassLinks/dac-as-java/Bar.html | 12 ++-------- .../format/dac/javaClassLinks/dac-as-java/Foo.html | 6 +---- .../format/dac/javaClassLinks/dac/Bar.html | 12 ++-------- .../format/dac/javaClassLinks/dac/Foo.html | 6 +---- .../dac/javaConstructor/dac-as-java/Foo.html | 6 +---- .../format/dac/javaConstructor/dac/Foo.html | 6 +---- .../javaDefaultConstructor/dac-as-java/Foo.html | 6 +---- .../format/dac/javaDefaultConstructor/dac/Foo.html | 6 +---- .../javaMethodVisibilities/dac-as-java/Foo.html | 24 ++++---------------- .../format/dac/javaMethodVisibilities/dac/Foo.html | 24 ++++---------------- .../format/dac/javaSeeTag/dac-as-java/Bar.html | 6 +---- .../format/dac/javaSeeTag/dac-as-java/Foo.html | 12 ++-------- core/testdata/format/dac/javaSeeTag/dac/Bar.html | 6 +---- core/testdata/format/dac/javaSeeTag/dac/Foo.html | 12 ++-------- 27 files changed, 48 insertions(+), 248 deletions(-) diff --git a/core/src/main/kotlin/Formats/DacHtmlFormat.kt b/core/src/main/kotlin/Formats/DacHtmlFormat.kt index b767c7d6f..7038a7fbe 100644 --- a/core/src/main/kotlin/Formats/DacHtmlFormat.kt +++ b/core/src/main/kotlin/Formats/DacHtmlFormat.kt @@ -9,7 +9,6 @@ import org.jetbrains.dokka.Kotlin.ParameterInfoNode import org.jetbrains.dokka.Utilities.firstSentence import java.lang.Math.max import java.net.URI -import java.util.Collections.emptyMap import kotlin.reflect.KClass /** @@ -481,7 +480,7 @@ class DevsiteLayoutHtmlFormatOutputBuilder( id = summaryId tbody { if (headerAsRow) { - developerHeading(header, summaryId) + developerHeading(header) } nodes.forEach { node -> row(node) @@ -919,25 +918,11 @@ class DevsiteLayoutHtmlFormatOutputBuilder( } } -fun TBODY.developerHeading( - header: String, - summaryId: String? = null -) { +fun TBODY.developerHeading(header: String) { tr { th { attributes["colSpan"] = "2" - dheading { - attributes["ds-is"] = "heading" - attributes["text"] = header - attributes["id"] = summaryId ?: header.replace("\\s".toRegex(), "-").toLowerCase() - attributes["level"] = "h3" - attributes["toc"] = "" - attributes["class"] = "" - h3 { - attributes["is-upgraded"] = "" - +header - } - } + +header } } } @@ -961,8 +946,3 @@ class DacAsJavaFormatDescriptor : JavaLayoutHtmlFormatDescriptorBase(), DefaultA override val packageListServiceClass: KClass = JavaLayoutHtmlPackageListService::class override val outputBuilderFactoryClass: KClass = DevsiteLayoutHtmlFormatOutputBuilderFactoryImpl::class } - -fun FlowOrPhrasingContent.dheading(block : DHEADING.() -> Unit = {}) : Unit = DHEADING(consumer).visit(block) - -class DHEADING(consumer: TagConsumer<*>) : - HTMLTag("devsite-heading", consumer, emptyMap(), inlineTag = false, emptyTag = false), HtmlBlockTag diff --git a/core/testdata/format/dac/deprecation/dac-as-java/Bar.html b/core/testdata/format/dac/deprecation/dac-as-java/Bar.html index 483929564..d77fa9e64 100644 --- a/core/testdata/format/dac/deprecation/dac-as-java/Bar.html +++ b/core/testdata/format/dac/deprecation/dac-as-java/Bar.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + diff --git a/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedBar.html b/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedBar.html index 71da6a1e8..56283f6e5 100644 --- a/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedBar.html +++ b/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedBar.html @@ -17,11 +17,7 @@
- -

Public methods

-
-
Public methods
final DeprecatedBar
- +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedFoo.html b/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedFoo.html index 8cf0c575d..e7e2fecb0 100644 --- a/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedFoo.html +++ b/core/testdata/format/dac/deprecation/dac-as-java/DeprecatedFoo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/deprecation/dac-as-java/Foo.html b/core/testdata/format/dac/deprecation/dac-as-java/Foo.html index b07ac3cc9..c898800da 100644 --- a/core/testdata/format/dac/deprecation/dac-as-java/Foo.html +++ b/core/testdata/format/dac/deprecation/dac-as-java/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + diff --git a/core/testdata/format/dac/deprecation/dac/Bar.html b/core/testdata/format/dac/deprecation/dac/Bar.html index 8b3e6c3fc..f20112e16 100644 --- a/core/testdata/format/dac/deprecation/dac/Bar.html +++ b/core/testdata/format/dac/deprecation/dac/Bar.html @@ -17,11 +17,7 @@
- -

Public methods

-
-
Public methods
static DeprecatedFoo
- +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + diff --git a/core/testdata/format/dac/deprecation/dac/DeprecatedBar.html b/core/testdata/format/dac/deprecation/dac/DeprecatedBar.html index 09758f061..15be9a06e 100644 --- a/core/testdata/format/dac/deprecation/dac/DeprecatedBar.html +++ b/core/testdata/format/dac/deprecation/dac/DeprecatedBar.html @@ -17,11 +17,7 @@
- -

Public methods

-
-
Public methods
DeprecatedBar
- +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/deprecation/dac/DeprecatedFoo.html b/core/testdata/format/dac/deprecation/dac/DeprecatedFoo.html index 16974894f..610c46b60 100644 --- a/core/testdata/format/dac/deprecation/dac/DeprecatedFoo.html +++ b/core/testdata/format/dac/deprecation/dac/DeprecatedFoo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/deprecation/dac/Foo.html b/core/testdata/format/dac/deprecation/dac/Foo.html index 7dcc84289..76c0760a0 100644 --- a/core/testdata/format/dac/deprecation/dac/Foo.html +++ b/core/testdata/format/dac/deprecation/dac/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + diff --git a/core/testdata/format/dac/inheritedMethods/dac-as-java/Child.html b/core/testdata/format/dac/inheritedMethods/dac-as-java/Child.html index a66d0bf6c..67a58125a 100644 --- a/core/testdata/format/dac/inheritedMethods/dac-as-java/Child.html +++ b/core/testdata/format/dac/inheritedMethods/dac-as-java/Child.html @@ -21,11 +21,7 @@
- -

Public methods

-
-
Public methods
open static DeprecatedFoo!
- +
- -

Public constructors

-
-
Public constructors
@@ -38,11 +34,7 @@ - + diff --git a/core/testdata/format/dac/inheritedMethods/dac-as-java/Parent.html b/core/testdata/format/dac/inheritedMethods/dac-as-java/Parent.html index 4efddeb30..dd305f7f8 100644 --- a/core/testdata/format/dac/inheritedMethods/dac-as-java/Parent.html +++ b/core/testdata/format/dac/inheritedMethods/dac-as-java/Parent.html @@ -38,11 +38,7 @@
- -

Public methods

-
-
Public methods
void
- +
- -

Public constructors

-
-
Public constructors
@@ -55,11 +51,7 @@ - + diff --git a/core/testdata/format/dac/inheritedMethods/dac/Child.html b/core/testdata/format/dac/inheritedMethods/dac/Child.html index 5da7f475d..dff52afbe 100644 --- a/core/testdata/format/dac/inheritedMethods/dac/Child.html +++ b/core/testdata/format/dac/inheritedMethods/dac/Child.html @@ -21,11 +21,7 @@
- -

Public methods

-
-
Public methods
void
- +
- -

Public constructors

-
-
Public constructors
@@ -38,11 +34,7 @@ - + @@ -63,11 +55,7 @@
- -

Public methods

-
-
Public methods
open Unit
- +
- -

Inherited functions

-
-
Inherited functions
diff --git a/core/testdata/format/dac/inheritedMethods/dac/Parent.html b/core/testdata/format/dac/inheritedMethods/dac/Parent.html index 0023368f0..ff9048b96 100644 --- a/core/testdata/format/dac/inheritedMethods/dac/Parent.html +++ b/core/testdata/format/dac/inheritedMethods/dac/Parent.html @@ -38,11 +38,7 @@ - +
- -

Public constructors

-
-
Public constructors
@@ -55,11 +51,7 @@ - + diff --git a/core/testdata/format/dac/javaClassLinks/dac-as-java/Bar.html b/core/testdata/format/dac/javaClassLinks/dac-as-java/Bar.html index 3d247edb8..cbabc2920 100644 --- a/core/testdata/format/dac/javaClassLinks/dac-as-java/Bar.html +++ b/core/testdata/format/dac/javaClassLinks/dac-as-java/Bar.html @@ -17,11 +17,7 @@
- -

Public methods

-
-
Public methods
open Unit
- +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + diff --git a/core/testdata/format/dac/javaClassLinks/dac-as-java/Foo.html b/core/testdata/format/dac/javaClassLinks/dac-as-java/Foo.html index 5717ecf6b..0ae4d255b 100644 --- a/core/testdata/format/dac/javaClassLinks/dac-as-java/Foo.html +++ b/core/testdata/format/dac/javaClassLinks/dac-as-java/Foo.html @@ -17,11 +17,7 @@
- -

Public methods

-
-
Public methods
Foo
- +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/javaClassLinks/dac/Bar.html b/core/testdata/format/dac/javaClassLinks/dac/Bar.html index 0c0c36714..87f2c3adf 100644 --- a/core/testdata/format/dac/javaClassLinks/dac/Bar.html +++ b/core/testdata/format/dac/javaClassLinks/dac/Bar.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + diff --git a/core/testdata/format/dac/javaClassLinks/dac/Foo.html b/core/testdata/format/dac/javaClassLinks/dac/Foo.html index dc7637b6a..51ba0204c 100644 --- a/core/testdata/format/dac/javaClassLinks/dac/Foo.html +++ b/core/testdata/format/dac/javaClassLinks/dac/Foo.html @@ -17,11 +17,7 @@
- -

Public methods

-
-
Public methods
open Foo!
- +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/javaConstructor/dac-as-java/Foo.html b/core/testdata/format/dac/javaConstructor/dac-as-java/Foo.html index 5717ecf6b..0ae4d255b 100644 --- a/core/testdata/format/dac/javaConstructor/dac-as-java/Foo.html +++ b/core/testdata/format/dac/javaConstructor/dac-as-java/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/javaConstructor/dac/Foo.html b/core/testdata/format/dac/javaConstructor/dac/Foo.html index dc7637b6a..51ba0204c 100644 --- a/core/testdata/format/dac/javaConstructor/dac/Foo.html +++ b/core/testdata/format/dac/javaConstructor/dac/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/javaDefaultConstructor/dac-as-java/Foo.html b/core/testdata/format/dac/javaDefaultConstructor/dac-as-java/Foo.html index 5717ecf6b..0ae4d255b 100644 --- a/core/testdata/format/dac/javaDefaultConstructor/dac-as-java/Foo.html +++ b/core/testdata/format/dac/javaDefaultConstructor/dac-as-java/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/javaDefaultConstructor/dac/Foo.html b/core/testdata/format/dac/javaDefaultConstructor/dac/Foo.html index dc7637b6a..51ba0204c 100644 --- a/core/testdata/format/dac/javaDefaultConstructor/dac/Foo.html +++ b/core/testdata/format/dac/javaDefaultConstructor/dac/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/javaMethodVisibilities/dac-as-java/Foo.html b/core/testdata/format/dac/javaMethodVisibilities/dac-as-java/Foo.html index 7f494c467..1ed04c547 100644 --- a/core/testdata/format/dac/javaMethodVisibilities/dac-as-java/Foo.html +++ b/core/testdata/format/dac/javaMethodVisibilities/dac-as-java/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + @@ -52,11 +44,7 @@
- -

Public methods

-
-
Public methods
void
- + @@ -70,11 +58,7 @@
- -

Protected methods

-
-
Protected methods
void
- + diff --git a/core/testdata/format/dac/javaMethodVisibilities/dac/Foo.html b/core/testdata/format/dac/javaMethodVisibilities/dac/Foo.html index 3f1e45107..0bcdcae90 100644 --- a/core/testdata/format/dac/javaMethodVisibilities/dac/Foo.html +++ b/core/testdata/format/dac/javaMethodVisibilities/dac/Foo.html @@ -17,11 +17,7 @@
- -

Private methods

-
-
Private methods
void
- +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + @@ -52,11 +44,7 @@
- -

Public methods

-
-
Public methods
open Unit
- + @@ -70,11 +58,7 @@
- -

Protected methods

-
-
Protected methods
open Unit
- + diff --git a/core/testdata/format/dac/javaSeeTag/dac-as-java/Bar.html b/core/testdata/format/dac/javaSeeTag/dac-as-java/Bar.html index 663d14727..6b4d75f4a 100644 --- a/core/testdata/format/dac/javaSeeTag/dac-as-java/Bar.html +++ b/core/testdata/format/dac/javaSeeTag/dac-as-java/Bar.html @@ -17,11 +17,7 @@
- -

Private methods

-
-
Private methods
open Unit
- +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/javaSeeTag/dac-as-java/Foo.html b/core/testdata/format/dac/javaSeeTag/dac-as-java/Foo.html index 6a6b5045c..b9f23dc59 100644 --- a/core/testdata/format/dac/javaSeeTag/dac-as-java/Foo.html +++ b/core/testdata/format/dac/javaSeeTag/dac-as-java/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + diff --git a/core/testdata/format/dac/javaSeeTag/dac/Bar.html b/core/testdata/format/dac/javaSeeTag/dac/Bar.html index c49e6d808..10a5f59ed 100644 --- a/core/testdata/format/dac/javaSeeTag/dac/Bar.html +++ b/core/testdata/format/dac/javaSeeTag/dac/Bar.html @@ -17,11 +17,7 @@
- -

Public methods

-
-
Public methods
void
- +
- -

Public constructors

-
-
Public constructors
diff --git a/core/testdata/format/dac/javaSeeTag/dac/Foo.html b/core/testdata/format/dac/javaSeeTag/dac/Foo.html index 14a913c99..7ca410c06 100644 --- a/core/testdata/format/dac/javaSeeTag/dac/Foo.html +++ b/core/testdata/format/dac/javaSeeTag/dac/Foo.html @@ -17,11 +17,7 @@ - +
- -

Public constructors

-
-
Public constructors
@@ -34,11 +30,7 @@ - + -- cgit v1.2.3 From b1a107c30e7fb43c8a00a60595f96698698ba942 Mon Sep 17 00:00:00 2001 From: Tiem Song Date: Fri, 8 May 2020 13:52:24 -0700 Subject: Rev version to g011 Test: N/A Bug: 157048140 Change-Id: I47a891d9fd2e2409f6757d7a892089c4f5b34189 Merged-In: I47a891d9fd2e2409f6757d7a892089c4f5b34189 --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 79056aa4c..a9e47b0bc 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,4 @@ -dokka_version=0.9.17-g010 +dokka_version=0.9.17-g011 dokka_publication_channel=dokka #Kotlin compiler and plugin -- cgit v1.2.3
- -

Public methods

-
-
Public methods
open Unit