diff --git a/docs/conf.py b/docs/conf.py index 87fc0fef..7bac58d2 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -43,7 +43,7 @@ 'sphinx_favicon', 'notfound.extension', # 'breathe', - # 'javasphinx', + 'javasphinx', 'sphinx_csharp.csharp', 'sphinxcontrib.makedomain', ] @@ -208,15 +208,15 @@ def setup(app): } )) - app.add_domain(custom_domain( - 'JavaDomain', - 'java', - 'Java', - { - 'class': { - }, - 'method': { - }, - } - )) + # app.add_domain(custom_domain( + # 'JavaDomain', + # 'java', + # 'Java', + # { + # 'class': { + # }, + # 'method': { + # }, + # } + # )) diff --git a/docs/java.rst b/docs/java.rst index 78b0c063..63e07695 100644 --- a/docs/java.rst +++ b/docs/java.rst @@ -1,5 +1,5 @@ Euler Java Implementation -======================= +========================= .. include:: ../java/README.rst :start-line: 2 @@ -49,11 +49,13 @@ build or test processes. Test Infrastructure ------------------- -.. java:class:: IEuler +.. java:type:: public interface IEuler .. java:method:: Object answer() -.. java:class:: EulerTest + :return: The answer to a Project Euler problem + +.. java:type:: public class EulerTest .. java:method:: void eulerTestProblem() diff --git a/docs/java/p0001.rst b/docs/java/p0001.rst index 787a48ad..69557db2 100644 --- a/docs/java/p0001.rst +++ b/docs/java/p0001.rst @@ -3,10 +3,12 @@ Java Implementation of Problem 1 View source code :source:`java/src/main/java/euler/p0001.java` -.. java:class:: p0001 implements Euler.IEuler +.. java:type:: public class p0001 implements IEuler .. java:method:: Object answer() + :return: The answer to Project Euler problem 1 + .. literalinclude:: ../../java/src/main/java/euler/p0001.java :language: java :linenos: diff --git a/docs/java/p0002.rst b/docs/java/p0002.rst index bd1d5e39..01623899 100644 --- a/docs/java/p0002.rst +++ b/docs/java/p0002.rst @@ -3,10 +3,12 @@ Java Implementation of Problem 2 View source code :source:`java/src/main/java/euler/p0002.java` -.. java:class:: p0002 implements Euler.IEuler +.. java:type:: public class p0002 implements IEuler .. java:method:: Object answer() + :return: The answer to Project Euler problem 2 + .. literalinclude:: ../../java/src/main/java/euler/p0002.java :language: java :linenos: diff --git a/docs/java/p0004.rst b/docs/java/p0004.rst index b0630518..4b53a58e 100644 --- a/docs/java/p0004.rst +++ b/docs/java/p0004.rst @@ -3,10 +3,12 @@ Java Implementation of Problem 4 View source code :source:`java/src/main/java/euler/p0004.java` -.. java:class:: p0004 implements Euler.IEuler +.. java:type:: public class p0004 implements IEuler .. java:method:: Object answer() + :return: The answer to Project Euler problem 4 + .. literalinclude:: ../../java/src/main/java/euler/p0004.java :language: java :linenos: diff --git a/docs/java/p0006.rst b/docs/java/p0006.rst index 554afef0..6e775bf1 100644 --- a/docs/java/p0006.rst +++ b/docs/java/p0006.rst @@ -3,10 +3,12 @@ Java Implementation of Problem 6 View source code :source:`java/src/main/java/euler/p0006.java` -.. java:class:: p0006 implements Euler.IEuler +.. java:type:: public class p0006 implements IEuler .. java:method:: Object answer() + :return: The answer to Project Euler problem 6 + .. literalinclude:: ../../java/src/main/java/euler/p0006.java :language: java :linenos: diff --git a/docs/java/p0009.rst b/docs/java/p0009.rst index f6e14b86..0b177dac 100644 --- a/docs/java/p0009.rst +++ b/docs/java/p0009.rst @@ -3,10 +3,12 @@ Java Implementation of Problem 9 View source code :source:`java/src/main/java/euler/p0009.java` -.. java:class:: p0009 implements Euler.IEuler +.. java:type:: public class p0009 implements IEuler .. java:method:: Object answer() + :return: The answer to Project Euler problem 9 + .. literalinclude:: ../../java/src/main/java/euler/p0009.java :language: java :linenos: diff --git a/docs/java/p0022.rst b/docs/java/p0022.rst index 3c610f9f..ef90a151 100644 --- a/docs/java/p0022.rst +++ b/docs/java/p0022.rst @@ -3,10 +3,12 @@ Java Implementation of Problem 22 View source code :source:`java/src/main/java/euler/p0022.java` -.. java:class:: p0022 implements Euler.IEuler +.. java:type:: public class p0022 implements IEuler .. java:method:: Object answer() + :return: The answer to Project Euler problem 22 + .. literalinclude:: ../../java/src/main/java/euler/p0022.java :language: java :linenos: diff --git a/docs/java/p0836.rst b/docs/java/p0836.rst index 8fdd696c..5acfb4c5 100644 --- a/docs/java/p0836.rst +++ b/docs/java/p0836.rst @@ -3,10 +3,12 @@ Java Implementation of Problem 836 View source code :source:`java/src/main/java/euler/p0836.java` -.. java:class:: p0836 implements Euler.IEuler +.. java:type:: public class p0836 implements IEuler .. java:method:: Object answer() + :return: The answer to Project Euler problem 836 + .. literalinclude:: ../../java/src/main/java/euler/p0836.java :language: java :linenos: diff --git a/docs/java/utils.rst b/docs/java/utils.rst index 072975a4..94d4a865 100644 --- a/docs/java/utils.rst +++ b/docs/java/utils.rst @@ -3,13 +3,22 @@ Utilities.java View source code :source:`java/src/main/java/euler/lib/Utilities.java` -.. java:class:: Utilities +.. java:type:: public class Utilities - .. java:method:: static string getDataFileText(string name) + .. java:method:: public static String getDataFileText(string name) - .. java:method:: static byte[] getDataFileBytes(string name) + :throws: IOException + :return: The contents of the given file in ``/_data`` - .. java:method:: static object getAnswer(ulong n) + .. java:method:: public static byte[] getDataFileBytes(string name) + + :throws: IOException + :return: The contents of the given file in ``/_data`` + + .. java:method:: public static Object getAnswer(ulong n) + + :throws: IOException + :return: The answer to the Project Euler problem in question .. literalinclude:: ../../java/src/main/java/euler/lib/Utilities.java :language: java diff --git a/docs/requirements.txt b/docs/requirements.txt index 9d20df3f..ae788d5a 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -8,3 +8,4 @@ ghlinguist matplotlib sphinx-favicon sphinx-notfound-page +javasphinx-workaround \ No newline at end of file