Skip to content
Permalink
Browse files

8242056: Merge support for AnnotationType builders/writers into suppo…

…rt for other types

Reviewed-by: hannesw
  • Loading branch information
jonathan-gibbons committed Apr 7, 2020
1 parent cceee2c commit 8523e37f7e3aebf50fb6ab592ace36b24042edc0
Showing with 197 additions and 1,474 deletions.
  1. +10 −15 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AbstractMemberWriter.java
  2. +0 −207 ...avadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeFieldWriterImpl.java
  3. +0 −223 ...jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/AnnotationTypeWriterImpl.java
  4. +45 −28 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ClassWriterImpl.java
  5. +3 −10 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDoclet.java
  6. +1 −3 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java
  7. +8 −8 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/Navigation.java
  8. +0 −2 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/SectionName.java
  9. +12 −39 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/WriterFactoryImpl.java
  10. +0 −111 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/AnnotationTypeFieldWriter.java
  11. +0 −159 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/AnnotationTypeWriter.java
  12. +38 −75 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/WriterFactory.java
  13. +0 −250 ...dk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeBuilder.java
  14. +0 −203 ...vadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/AnnotationTypeFieldBuilder.java
  15. +8 −48 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/BuilderFactory.java
  16. +51 −42 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/ClassBuilder.java
  17. +4 −37 ...jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/MemberSummaryBuilder.java
  18. +2 −1 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/util/IndexBuilder.java
  19. +8 −4 src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/util/VisibleMemberTable.java
  20. +5 −6 test/langtools/jdk/javadoc/doclet/testAnnotationTypes/TestAnnotationTypes.java
  21. +1 −1 test/langtools/jdk/javadoc/doclet/testDeprecatedDocs/TestDeprecatedDocs.java
  22. +1 −2 test/langtools/jdk/javadoc/doclet/testMetadata/TestMetadata.java
@@ -626,21 +626,16 @@ private void appendModifiers(Content htmltree) {
set.remove(STRICTFP);

// According to JLS, we should not be showing public modifier for
// interface methods.
if ((utils.isField(element) || utils.isMethod(element))
&& ((writer instanceof ClassWriterImpl
&& utils.isInterface(((ClassWriterImpl) writer).getTypeElement()) ||
writer instanceof AnnotationTypeWriterImpl) )) {
// Remove the implicit abstract and public modifiers
if (utils.isMethod(element) &&
(utils.isInterface(element.getEnclosingElement()) ||
utils.isAnnotationType(element.getEnclosingElement()))) {
set.remove(ABSTRACT);
set.remove(PUBLIC);
}
if (!utils.isMethod(element)) {
set.remove(PUBLIC);
}
// interface methods and fields.
if ((utils.isField(element) || utils.isMethod(element))) {
Element te = element.getEnclosingElement();
if (utils.isInterface(te) || utils.isAnnotationType(te)) {
// Remove the implicit abstract and public modifiers
if (utils.isMethod(element)) {
set.remove(ABSTRACT);
}
set.remove(PUBLIC);
}
}
if (!set.isEmpty()) {
String mods = set.stream().map(Modifier::toString).collect(Collectors.joining(" "));

This file was deleted.

0 comments on commit 8523e37

Please sign in to comment.