lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nightowl...@apache.org
Subject [03/11] lucenenet git commit: JavaDocToMarkdownConverter: Added code to correct case of the character following # and change # to . in crefs.
Date Thu, 14 Sep 2017 05:48:24 GMT
JavaDocToMarkdownConverter: Added code to correct case of the character following # and change
# to . in crefs.


Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/03256c39
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/03256c39
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/03256c39

Branch: refs/heads/master
Commit: 03256c39aedc58bd4690e4d3d4ecf8fc4629a5db
Parents: 928f68d
Author: Shad Storhaug <shad@shadstorhaug.com>
Authored: Thu Sep 14 12:33:41 2017 +0700
Committer: Shad Storhaug <shad@shadstorhaug.com>
Committed: Thu Sep 14 12:33:41 2017 +0700

----------------------------------------------------------------------
 .../JavaDocToMarkdownConverter/DocConverter.cs            | 10 ++++++++++
 1 file changed, 10 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/03256c39/src/dotnet/tools/JavaDocToMarkdownConverter/JavaDocToMarkdownConverter/DocConverter.cs
----------------------------------------------------------------------
diff --git a/src/dotnet/tools/JavaDocToMarkdownConverter/JavaDocToMarkdownConverter/DocConverter.cs
b/src/dotnet/tools/JavaDocToMarkdownConverter/JavaDocToMarkdownConverter/DocConverter.cs
index e60b225..4ac7420 100644
--- a/src/dotnet/tools/JavaDocToMarkdownConverter/JavaDocToMarkdownConverter/DocConverter.cs
+++ b/src/dotnet/tools/JavaDocToMarkdownConverter/JavaDocToMarkdownConverter/DocConverter.cs
@@ -197,6 +197,16 @@ namespace JavaDocToMarkdownConverter
                 temp = temp.Replace(item.Key, item.Value);
             }
 
+            int index = temp.IndexOf('#');
+            if (index > -1)
+            {
+                var sb = new StringBuilder(temp);
+                // special case - capitalize char after #
+                sb[index + 1] = char.ToUpperInvariant(sb[index + 1]);
+                // special case - replace Java # with .
+                temp = sb.ToString().Replace('#', '.');
+            }
+
             return temp;
         }
 


Mime
View raw message