JDK-4935515 : Cannot override Javadoc's sentence bounary algorithm
  • Type: Enhancement
  • Component: tools
  • Sub-Component: javadoc(tool)
  • Affected Version: 1.4.2
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2003-10-09
  • Updated: 2003-10-10
  • Resolved: 2003-10-10
Related Reports
Duplicate :  
Description

Name: rmT116609			Date: 10/09/2003


A DESCRIPTION OF THE REQUEST :
At times Javadoc incorrectly interprets the sentence bounaries in Javadoc comments.

Ex: "Looks for occurances of the ? conditional-operator." is incorrectly interpreted by current BreakIterator algorithm as: "Looks for occurances of the ?" followed by "conditional-operator."

It would be useful if there was a way to insert explicit sentence startpoint/endpoint markers in these cases to override the default algorithm.

JUSTIFICATION :
Presently, there is no way to construct single sentences that contain one of the sequences of characters that are interpreted to be sentence-boundary markers.

EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
It would be convienient if there was a method to explicitly define where the sentence boundaries are by inserting markers in the source-code.

One way might be to allow a construct similar to:
"<sentence>Looks for occurances of the ? conditional-operator.</sentence>"

This construct would tell Javadoc to override its default sentence-boundary algorithm and use the sentence boundary points explictly defined in the source-code.
ACTUAL -
Sentence boundaries can only be detected through the default algorithm. There is no way to override its behavior.

---------- BEGIN SOURCE ----------
class Test {
/**
  * Looks for occurances of the ? conditional-operator.
  */
public static void findConditionalOperator() {
     // ...
}
}
---------- END SOURCE ----------
(Incident Review ID: 209127) 
======================================================================

Comments
PUBLIC COMMENTS -
10-06-2004