Skip to content

Commit

Permalink
Update docs to be prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
LivInTheLookingGlass committed Aug 9, 2024
1 parent 5703084 commit a86573b
Show file tree
Hide file tree
Showing 11 changed files with 52 additions and 26 deletions.
24 changes: 12 additions & 12 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
'sphinx_favicon',
'notfound.extension',
# 'breathe',
# 'javasphinx',
'javasphinx',
'sphinx_csharp.csharp',
'sphinxcontrib.makedomain',
]
Expand Down Expand Up @@ -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': {
# },
# }
# ))

8 changes: 5 additions & 3 deletions docs/java.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Euler Java Implementation
=======================
=========================

.. include:: ../java/README.rst
:start-line: 2
Expand Down Expand Up @@ -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()
Expand Down
4 changes: 3 additions & 1 deletion docs/java/p0001.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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:
4 changes: 3 additions & 1 deletion docs/java/p0002.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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:
4 changes: 3 additions & 1 deletion docs/java/p0004.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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:
4 changes: 3 additions & 1 deletion docs/java/p0006.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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:
4 changes: 3 additions & 1 deletion docs/java/p0009.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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:
4 changes: 3 additions & 1 deletion docs/java/p0022.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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:
4 changes: 3 additions & 1 deletion docs/java/p0836.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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:
17 changes: 13 additions & 4 deletions docs/java/utils.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
1 change: 1 addition & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ ghlinguist
matplotlib
sphinx-favicon
sphinx-notfound-page
javasphinx-workaround

0 comments on commit a86573b

Please sign in to comment.