Skip to content

Commit a2f3d58

Browse files
committed
Improve Chain Javadoc
1 parent 9a08e35 commit a2f3d58

File tree

1 file changed

+10
-4
lines changed
  • chain/src/main/java/com/iluwatar/chain

1 file changed

+10
-4
lines changed

chain/src/main/java/com/iluwatar/chain/App.java

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,16 @@
22

33
/**
44
*
5-
* Chain of Responsibility organizes request handlers ({@link RequestHandler}) into a
6-
* chain where each handler has a chance to act on the request on its turn. In
7-
* this example the king ({@link OrcKing}) makes requests and the military orcs
8-
* ({@link OrcCommander}, {@link OrcOfficer}, {@link OrcSoldier}) form the handler chain.
5+
* The Chain of Responsibility pattern is a design pattern consisting of command
6+
* objects and a series of processing objects. Each processing object contains
7+
* logic that defines the types of command objects that it can handle; the rest are
8+
* passed to the next processing object in the chain. A mechanism also exists for
9+
* adding new processing objects to the end of this chain.
10+
* <p>
11+
* In this example we organize the request handlers ({@link RequestHandler}) into a
12+
* chain where each handler has a chance to act on the request on its turn. Here
13+
* the king ({@link OrcKing}) makes requests and the military orcs ({@link OrcCommander},
14+
* {@link OrcOfficer}, {@link OrcSoldier}) form the handler chain.
915
*
1016
*/
1117
public class App {

0 commit comments

Comments
 (0)