Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 2bc2384

Browse files
committed
iluwatar#107 Improve JavaDoc for Null Object example
1 parent 952ebc6 commit 2bc2384

File tree

3 files changed

+11
-2
lines changed

3 files changed

+11
-2
lines changed

null-object/src/main/java/com/iluwatar/nullobject/App.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,18 @@
55
* Null Object pattern replaces null values with neutral objects.
66
* Many times this simplifies algorithms since no extra null checks
77
* are needed.
8-
*
8+
* <p>
99
* In this example we build a binary tree where the nodes are either
1010
* normal or Null Objects. No null values are used in the tree making
1111
* the traversal easy.
1212
*
1313
*/
1414
public class App
1515
{
16+
/**
17+
* Program entry point
18+
* @param args command line args
19+
*/
1620
public static void main( String[] args ) {
1721

1822
Node root = new NodeImpl("1",

null-object/src/main/java/com/iluwatar/nullobject/NullNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
/**
44
*
55
* Null Object implementation for binary tree node.
6-
*
6+
* <p>
77
* Implemented as Singleton, since all the NullNodes are the same.
88
*
99
*/

null-object/src/test/java/com/iluwatar/nullobject/AppTest.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@
44

55
import com.iluwatar.nullobject.App;
66

7+
/**
8+
*
9+
* Application test
10+
*
11+
*/
712
public class AppTest {
813

914
@Test

0 commit comments

Comments
 (0)