< prev index next >

src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/LinkFactoryImpl.java

Print this page

        

@@ -39,11 +39,10 @@
 import jdk.javadoc.internal.doclets.toolkit.BaseConfiguration;
 import jdk.javadoc.internal.doclets.toolkit.Content;
 import jdk.javadoc.internal.doclets.toolkit.Resources;
 import jdk.javadoc.internal.doclets.toolkit.util.DocPath;
 import jdk.javadoc.internal.doclets.toolkit.util.DocPaths;
-import jdk.javadoc.internal.doclets.toolkit.util.DocletConstants;
 import jdk.javadoc.internal.doclets.toolkit.util.links.LinkFactory;
 import jdk.javadoc.internal.doclets.toolkit.util.links.LinkInfo;
 
 /**
  * A factory that returns a link given the information about it.

@@ -133,11 +132,11 @@
 
     /**
      * {@inheritDoc}
      */
     @Override
-    protected Content getTypeParameterLinks(LinkInfo linkInfo, boolean isClassLabel) {
+    protected Content getTypeParameterLinks(LinkInfo linkInfo, boolean isClassLabel){
         Content links = newContent();
         List<TypeMirror> vars = new ArrayList<>();
         TypeMirror ctype = linkInfo.type != null
                 ? utils.getComponentType(linkInfo.type)
                 : null;

@@ -163,13 +162,10 @@
             boolean many = false;
             for (TypeMirror t : vars) {
                 if (many) {
                     links.add(",");
                     links.add(Entity.ZERO_WIDTH_SPACE);
-                    if (((LinkInfoImpl) linkInfo).getContext() == LinkInfoImpl.Kind.MEMBER_TYPE_PARAMS) {
-                        links.add(DocletConstants.NL);
-                    }
                 }
                 links.add(getTypeParameterLink(linkInfo, t));
                 many = true;
             }
             links.add(">");

@@ -188,10 +184,11 @@
         LinkInfoImpl typeLinkInfo = new LinkInfoImpl(m_writer.configuration,
                 ((LinkInfoImpl) linkInfo).getContext(), typeParam);
         typeLinkInfo.excludeTypeBounds = linkInfo.excludeTypeBounds;
         typeLinkInfo.excludeTypeParameterLinks = linkInfo.excludeTypeParameterLinks;
         typeLinkInfo.linkToSelf = linkInfo.linkToSelf;
+        typeLinkInfo.isJava5DeclarationLocation = false;
         return getLink(typeLinkInfo);
     }
 
     @Override
     public Content getTypeAnnotationLinks(LinkInfo linkInfo) {

@@ -219,11 +216,11 @@
         }
 
         if (annotations.isEmpty())
             return links;
 
-        List<Content> annos = m_writer.getAnnotations(annotations, false);
+        List<Content> annos = m_writer.getAnnotations(0, annotations, false, linkInfo.isJava5DeclarationLocation);
 
         boolean isFirst = true;
         for (Content anno : annos) {
             if (!isFirst) {
                 links.add(" ");
< prev index next >