Java Solaris Communities Sun Store Join SDN My Profile Why Join?
 
Bug Database
Bug Detail
Quick Lists
Top 25 Bugs
Top 25 RFE's
Recently Closed Bugs
Printable Page Printable Page


Bug Database
Bug ID: 4920381
Votes 59
Synopsis REGRESSION: Tag name containing dash not allowed
Category doclet:tbd
Reported Against 1.4.2 , mantis
Release Fixed 1.5(tiger-b30)
State 10-Fix Delivered, bug
Priority: 3-Medium
Related Bugs 4893804 , 4893808
Submit Date 10-SEP-2003
Description
Problem submitted to Javadoc Forum
http://forum.java.sun.com/thread.jsp?forum=41&thread=432943&tstart=0&trange=50

If I understand right the documentation, there is a major change
in the behaviour of the -tag option between 1.4.1 and 1.4.2:

New feature: The -tag option now allows dash (-) separator for xdoclet
              tags like @ejb:bean (4750173, stddoclet)

I had a minus (-) in the text which should replace the custom tag
(a range of years like 1983-2003).
I called javadoc like this:
jdk142/bin/javadoc.exe -tag my.tag:t:A-B" class1.java

But I get now the following messages:
class1.java:2: warning - @my.tag is an unknown tag.
Note: Custom tags that were not seen: @my.tag:t:A

What is the best way to pass a '-'?
It should also work with ant because I use it to generate my documentation.

Work Around
The only workaround that I know of is to write your own taglet instead
of using the -tag option. Here is what I would use:

import com.sun.tools.doclets.standard.tags.SimpleTaglet;

public class Foo extends SimpleTaglet {
   public Foo() {
     super("my-tag", "My Tag:", "a");
   }
}

Then, when you run Javadoc, use:

-taglet <qualified name of your taglet> -tagletpath <path to your taglet>

I don't have time to test this code, but I believe it will work.

-Jamie
Evaluation
  xxxxx@xxxxx   wrote:

Here is the bug you are running into:

String seperator = args[1].indexOf(TagletManager.ALT_SIMPLE_TAGLET_OPT_SEPERATOR) == -1 ?
TagletManager.SIMPLE_TAGLET_OPT_SEPERATOR :
TagletManager.ALT_SIMPLE_TAGLET_OPT_SEPERATOR;

The doclet assumes that the seperator is "-" instead of ":".
This code was added in 1.4.2 t support tags like @my:tag.
I don't think anyone knew that people used tags like @my-tag.
This will have to be fixed in 1.5.

See the workaround.

  xxxxx@xxxxx   2003-09-10

Fixed.
  xxxxx@xxxxx   2003-11-15
Comments
  
  Include a link with my name & email   

Submitted On 26-SEP-2003
MadPenguin
What prevents it being fixed any sooner (e.g. the next 1.4.2
build)?
I find the reason given above ("support tags like @my:tag")
particularly ironic, since we (XDoclet) switched some time
ago from @my:tag to @my.tag as the preferred form of our
tags, to avoid these problems with : being used as the
separator...


Submitted On 23-FEB-2006
Chris_Nappin
It is not acceptable to not fix this fault for JDK 1.4.2.

Like many software houses, we are unable to use JDK 1.5 because our customers are using Application Servers that do not support it.

Can this fault please be fixed for JDK 1.4.2?



PLEASE NOTE: JDK6 is formerly known as Project Mustang