Try to use the html entities for such type of special characters...
Say if you have special character < its html entity equivalent is < and for > is >
So for your constants you can use this way...."<something>" ---> "<something>"
You can find the html entity equivalents for all such type of special chars at http://www.utexas.edu/learn/html/spchar.html
If this post answers your question or helps, please kindly mark it as such.
It only works while documenting, but it doesn't work in the application, so I think this is not the way to fix it. Any other idea?
You may have found a bug in the ASDoc generator. Can you please give an explicit example of a declaration-with-ASDoc-comment that causes this problem?
Adobe Flex SDK Team
Sure, here is what I am seeing:
Several AS3 classes of my code have public constants like these:
/** RCI protocol end tag*/
public static const RCI_TAIL:String = "</rci_request>";
/** do_command end tag*/
public static const RCI_DO_COMMAND_TAIL:String = "</do_command>";
/** data opening tag*/
public static const RCI_DATA_HEADER:String = "<data>";
/** data end tag*/
public static const RCI_DATA_TAIL:String = "</data>";
With those constants I build XML strings and objects that are sent to a web service. If I try to generate documentation for those classes, this is what is displayed in the html page:
RCI_DATA_TAIL : String =
[static] data end tag
RCI_DO_COMMAND_TAIL : String =
[static] do_command end tag
RCI_DATA_HEADER : String =
[static] data opening tag
RCI_DATA_TAIL : String =[static] data end tag
As you can see no value is displayed, however other constants have their value correctly displayed like this one:
[static] HTTP protocol prefix
I am pretty sure it is because of the "<" and ">" characters of the variable. I cannot replace them by < and > because if I do so, my XML strings and objects won't work in my program. However, if I replace them, the documentation is correctly generated.
Hope that helps.
PS: This is happening in variables and also in comments, I have just tried it.
This definitely sounds like a bug in the ASDoc generator. Could you please file a bug, with this code as an example?
As a possible workaround, try writing the < and > inside the String literals as \u003C and \u003E. If that doesn't work, I think you're out of luck until the bug is fixed unless you want to try to fix it yourself. I'm pretty sure that the ASDoc generator is opensource.
BTW, it seems strange to have public constants for the syntax of each XML start/end tag. Why not have strings like RCI_REQUEST, DO_COMMAND, and DATA for the tag names? Those wouldn't cause any problems.