< prev index next >

src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/builders/EnumConstantBuilder.java

Print this page

        

@@ -124,22 +124,23 @@
         }
         if (hasMembersToDocument()) {
             Content enumConstantsDetailsTreeHeader = writer.getEnumConstantsDetailsTreeHeader(typeElement,
                     memberDetailsTree);
             Content enumConstantsDetailsTree = writer.getMemberTreeHeader();
-
+            Element lastElement = enumConstants.get(enumConstants.size() - 1);
             for (Element enumConstant : enumConstants) {
                 currentElement = (VariableElement)enumConstant;
                 Content enumConstantsTree = writer.getEnumConstantsTreeHeader(currentElement,
                         enumConstantsDetailsTree);
 
                 buildSignature(enumConstantsTree);
                 buildDeprecationInfo(enumConstantsTree);
                 buildEnumConstantComments(enumConstantsTree);
                 buildTagInfo(enumConstantsTree);
 
-                enumConstantsDetailsTree.add(writer.getEnumConstants(enumConstantsTree));
+                enumConstantsDetailsTree.add(writer.getEnumConstants(
+                        enumConstantsTree, currentElement == lastElement));
             }
             memberDetailsTree.add(
                     writer.getEnumConstantsDetails(enumConstantsDetailsTreeHeader, enumConstantsDetailsTree));
         }
     }
< prev index next >