langtools/src/share/classes/com/sun/tools/doclets/formats/html/markup/HtmlDocWriter.java
changeset 1787 1aa079321cd2
parent 10 06bc494ca11e
child 1869 0e193a8f3520
equal deleted inserted replaced
1753:d4c11dcedac3 1787:1aa079321cd2
    81      *
    81      *
    82      * @param link String name of the file.
    82      * @param link String name of the file.
    83      * @param where Position of the link in the file. Character '#' is not
    83      * @param where Position of the link in the file. Character '#' is not
    84      * needed.
    84      * needed.
    85      * @param label Tag for the link.
    85      * @param label Tag for the link.
    86      * @param bold  Boolean that sets label to bold.
    86      * @param strong  Boolean that sets label to strong.
    87      */
    87      */
    88     public void printHyperLink(String link, String where,
    88     public void printHyperLink(String link, String where,
    89                                String label, boolean bold) {
    89                                String label, boolean strong) {
    90         print(getHyperLink(link, where, label, bold, "", "", ""));
    90         print(getHyperLink(link, where, label, strong, "", "", ""));
    91     }
    91     }
    92 
    92 
    93     /**
    93     /**
    94      * Print Html Hyper Link.
    94      * Print Html Hyper Link.
    95      *
    95      *
   107      *
   107      *
   108      * @param link       String name of the file.
   108      * @param link       String name of the file.
   109      * @param where      Position of the link in the file. Character '#' is not
   109      * @param where      Position of the link in the file. Character '#' is not
   110      * needed.
   110      * needed.
   111      * @param label      Tag for the link.
   111      * @param label      Tag for the link.
   112      * @param bold       Boolean that sets label to bold.
   112      * @param strong       Boolean that sets label to strong.
   113      * @param stylename  String style of text defined in style sheet.
   113      * @param stylename  String style of text defined in style sheet.
   114      */
   114      */
   115     public void printHyperLink(String link, String where,
   115     public void printHyperLink(String link, String where,
   116                                String label, boolean bold,
   116                                String label, boolean strong,
   117                                String stylename) {
   117                                String stylename) {
   118         print(getHyperLink(link, where, label, bold, stylename, "", ""));
   118         print(getHyperLink(link, where, label, strong, stylename, "", ""));
   119     }
   119     }
   120 
   120 
   121     /**
   121     /**
   122      * Return Html Hyper Link string.
   122      * Return Html Hyper Link string.
   123      *
   123      *
   124      * @param link       String name of the file.
   124      * @param link       String name of the file.
   125      * @param where      Position of the link in the file. Character '#' is not
   125      * @param where      Position of the link in the file. Character '#' is not
   126      * needed.
   126      * needed.
   127      * @param label      Tag for the link.
   127      * @param label      Tag for the link.
   128      * @param bold       Boolean that sets label to bold.
   128      * @param strong       Boolean that sets label to strong.
   129      * @return String    Hyper Link.
   129      * @return String    Hyper Link.
   130      */
   130      */
   131     public String getHyperLink(String link, String where,
   131     public String getHyperLink(String link, String where,
   132                                String label, boolean bold) {
   132                                String label, boolean strong) {
   133         return getHyperLink(link, where, label, bold, "", "", "");
   133         return getHyperLink(link, where, label, strong, "", "", "");
   134     }
   134     }
   135 
   135 
   136     /**
   136     /**
   137      * Get Html Hyper Link string.
   137      * Get Html Hyper Link string.
   138      *
   138      *
   139      * @param link       String name of the file.
   139      * @param link       String name of the file.
   140      * @param where      Position of the link in the file. Character '#' is not
   140      * @param where      Position of the link in the file. Character '#' is not
   141      *                   needed.
   141      *                   needed.
   142      * @param label      Tag for the link.
   142      * @param label      Tag for the link.
   143      * @param bold       Boolean that sets label to bold.
   143      * @param strong       Boolean that sets label to strong.
   144      * @param stylename  String style of text defined in style sheet.
   144      * @param stylename  String style of text defined in style sheet.
   145      * @return String    Hyper Link.
   145      * @return String    Hyper Link.
   146      */
   146      */
   147     public String getHyperLink(String link, String where,
   147     public String getHyperLink(String link, String where,
   148                                String label, boolean bold,
   148                                String label, boolean strong,
   149                                String stylename) {
   149                                String stylename) {
   150         return getHyperLink(link, where, label, bold, stylename, "", "");
   150         return getHyperLink(link, where, label, strong, stylename, "", "");
   151     }
   151     }
   152 
   152 
   153     /**
   153     /**
   154      * Get Html Hyper Link string.
   154      * Get Html Hyper Link string.
   155      *
   155      *
   156      * @param link       String name of the file.
   156      * @param link       String name of the file.
   157      * @param where      Position of the link in the file. Character '#' is not
   157      * @param where      Position of the link in the file. Character '#' is not
   158      *                   needed.
   158      *                   needed.
   159      * @param label      Tag for the link.
   159      * @param label      Tag for the link.
   160      * @param bold       Boolean that sets label to bold.
   160      * @param strong       Boolean that sets label to strong.
   161      * @param stylename  String style of text defined in style sheet.
   161      * @param stylename  String style of text defined in style sheet.
   162      * @param title      String that describes the link's content for accessibility.
   162      * @param title      String that describes the link's content for accessibility.
   163      * @param target     Target frame.
   163      * @param target     Target frame.
   164      * @return String    Hyper Link.
   164      * @return String    Hyper Link.
   165      */
   165      */
   166     public String getHyperLink(String link, String where,
   166     public String getHyperLink(String link, String where,
   167                                String label, boolean bold,
   167                                String label, boolean strong,
   168                                String stylename, String title, String target) {
   168                                String stylename, String title, String target) {
   169         StringBuffer retlink = new StringBuffer();
   169         StringBuffer retlink = new StringBuffer();
   170         retlink.append("<A HREF=\"");
   170         retlink.append("<A HREF=\"");
   171         retlink.append(link);
   171         retlink.append(link);
   172         if (where != null && where.length() != 0) {
   172         if (where != null && where.length() != 0) {
   184         if (stylename != null && stylename.length() != 0) {
   184         if (stylename != null && stylename.length() != 0) {
   185             retlink.append("<FONT CLASS=\"");
   185             retlink.append("<FONT CLASS=\"");
   186             retlink.append(stylename);
   186             retlink.append(stylename);
   187             retlink.append("\">");
   187             retlink.append("\">");
   188         }
   188         }
   189         if (bold) {
   189         if (strong) {
   190             retlink.append("<B>");
   190             retlink.append("<STRONG>");
   191         }
   191         }
   192         retlink.append(label);
   192         retlink.append(label);
   193         if (bold) {
   193         if (strong) {
   194             retlink.append("</B>");
   194             retlink.append("</STRONG>");
   195         }
   195         }
   196         if (stylename != null && stylename.length() != 0) {
   196         if (stylename != null && stylename.length() != 0) {
   197             retlink.append("</FONT>");
   197             retlink.append("</FONT>");
   198         }
   198         }
   199         retlink.append("</A>");
   199         retlink.append("</A>");