Skip to content

Commit 119abf3

Browse files
authored
Doc: Corrected a few spelling mistakes (iluwatar#1840)
1 parent 87cc4df commit 119abf3

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

active-object/README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ tags:
1111

1212

1313
## Intent
14-
The active object design pattern decouples method execution from method invocation for objects that each reside in their thread of control. The goal is to introduce concurrency, by using asynchronous method invocation and a scheduler for handling requests.
14+
The active object design pattern decouples method execution from method invocation for objects that each reside in their thread of control. The goal is to introduce concurrency, by using asynchronous method invocation, and a scheduler for handling requests.
1515

1616
## Explanation
1717

@@ -70,7 +70,7 @@ public abstract class ActiveCreature{
7070
requests.put(new Runnable() {
7171
@Override
7272
public void run() {
73-
logger.info("{} has started to roam and the wastelands.",name());
73+
logger.info("{} has started to roam the wastelands.",name());
7474
}
7575
}
7676
);
@@ -82,7 +82,7 @@ public abstract class ActiveCreature{
8282
}
8383
```
8484

85-
We can see that any class that will extend the ActiveCreature class will have its own thread of control to execute and invocate methods.
85+
We can see that any class that will extend the ActiveCreature class will have its own thread of control to invoke and execute methods.
8686

8787
For example, the Orc class:
8888

@@ -96,7 +96,7 @@ public class Orc extends ActiveCreature {
9696
}
9797
```
9898

99-
Now, we can create multiple creatures such as Orcs, tell them to eat and roam and they will execute it on their own thread of control:
99+
Now, we can create multiple creatures such as Orcs, tell them to eat and roam, and they will execute it on their own thread of control:
100100

101101
```java
102102
public static void main(String[] args) {

active-object/src/main/java/com/iluwatar/activeobject/ActiveCreature.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ public void eat() throws InterruptedException {
8282
}
8383

8484
/**
85-
* Roam in the wastelands.
85+
* Roam the wastelands.
8686
* @throws InterruptedException due to firing a new Runnable.
8787
*/
8888
public void roam() throws InterruptedException {

0 commit comments

Comments
 (0)