Skip to content

Conversation

@caitlinrussell
Copy link

  • 7bc879f: Add Javadoc where it was missing, mostly for @param and @return on buildRequest()
  • 7c7b079: Add @param programmatically for action parameters
  • 3cc433e: Replace invalid characters with HTML equivalent. We will need to do this later for .NET as well. The HTML is escaped in the XML metadata, but gets translated back to encoded characters during the template writing process.

Caitlin Bales (MSFT) added 3 commits February 22, 2018 17:33
HTML characters get re-encoded into <,>,&, etc at this point, so we need to turn them back into HTML characters so that Javadoc accepts them as valid
public string ReplaceInvalidCharacters(string inputString)
{
if (inputString != null) {
return inputString.Replace("<", "&lt;").Replace(">", "&gt;").Replace("&", "&amp;");
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are '<', '>', and '&' the only characters we need to consider replacing?

http://www.javapractices.com/topic/TopicAction.do?Id=96

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I could not find a good document that outlined invalid characters that Javadoc doesn't like. Javadoc by default will convert the comments to valid HTML, so we don't need to worry about escaping quotes, slashes, etc.
I tested some common characters and didn't find anything that the compiler complained about:

@ { } % $ # [ ] | ^ ~ ; ? = : * \ " ' 

@caitlinrussell caitlinrussell merged commit d6a6ae2 into dev Mar 8, 2018
@caitlinrussell caitlinrussell deleted the javadoc-cleanup branch March 8, 2018 19:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants