From b46305c1d95aee4a60742f22586c194b024eef73 Mon Sep 17 00:00:00 2001 From: Malte Schmitz Date: Sun, 17 Dec 2017 21:06:20 +0100 Subject: [PATCH] Update documentation --- README.md | 30 +++++++++++++++++++++++++++--- src/main/java/interpreter/Visitor.java | 2 +- 2 files changed, 28 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 6c6d4f3..d6b4849 100644 --- a/README.md +++ b/README.md @@ -18,9 +18,33 @@ while (a) { ## Literate Programming Documentation -The code is documented in a literate programming style using [Atlassian Docco](https://bitbucket.org/doklovic_atlassian/atlassian-docco) - -Have a look a the [Parser](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/parser/Parser.java.html) and the [Interpreter](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/interpreter/Interpreter.java.html) where the formal syntax and semantics are defined, too. +The code is documented in a literate programming style using [Atlassian Docco](https://bitbucket.org/brainicorn/atlassian-docco) + +- **Expression** + - [Addition.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/expression/Addition.java.html) + - [Expression.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/expression/Expression.java.html) + - [Identifier.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/expression/Identifier.java.html) + - [Int.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/expression/Int.java.html) + - [Subtraction.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/expression/Subtraction.java.html) +- **Interpreter** + - [Evaluator.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/interpreter/Evaluator.java.html) + - [Interpreter.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/interpreter/Interpreter.java.html) + - [InterpreterException.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/interpreter/InterpreterException.java.html) + - [Visitor.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/interpreter/Visitor.java.html) +- **Parser** + - [Parser.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/parser/Parser.java.html) + - [SyntaxException.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/parser/SyntaxException.java.html) +- **Printer** + - [ExpressionPrinter.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/printer/ExpressionPrinter.java.html) + - [ProgramPrinter.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/printer/ProgramPrinter.java.html) +- **Program** + - [Assignment.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/program/Assignment.java.html) + - [Composition.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/program/Composition.java.html) + - [Conditional.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/program/Conditional.java.html) + - [Loop.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/program/Loop.java.html) + - [Program.java](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/program/Program.java.html) + +Start with the [Parser](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/parser/Parser.java.html) and the [Interpreter](https://malteschmitz.github.io/WhileInterpreter/docco/vertical/src/main/java/interpreter/Interpreter.java.html) where the formal syntax and semantics of the _while prorgrams_ are defined. ## Building diff --git a/src/main/java/interpreter/Visitor.java b/src/main/java/interpreter/Visitor.java index 53a4b47..fa4e505 100644 --- a/src/main/java/interpreter/Visitor.java +++ b/src/main/java/interpreter/Visitor.java @@ -17,7 +17,7 @@ package interpreter; /*! This `Visitor` is implemented using -[Reflection](https://en.wikipedia.org/wiki/Reflection_(computer_programming)). That is kind of cheating, but simplifies +[Reflection](http://www.oracle.com/technetwork/articles/java/javareflection-1536171.html). That is kind of cheating, but simplifies the classical Visitor pattern a lot. Of course the performance is bad, but performance is not an issue in this little demonstration and actually there are a lot of other performance issues as well. */ public abstract class Visitor {