Skip to content

Commit 97683cb

Browse files
committed
Update README.md
1 parent 23e71c9 commit 97683cb

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ Now you're ready to execute commands.
6161
This code sends a simple ping to nameapi to test the connection:
6262

6363
```java
64-
PingerCommand command = new PingerCommand();
65-
executor.execute(command, mode, null).get().getPong(); //returns "pong"
64+
PingCommand command = new PingCommand();
65+
executor.execute(command, mode, null).get(); //returns "pong"
6666
```
6767

6868

@@ -124,7 +124,7 @@ Using the objects created earlier:
124124

125125
```java
126126
PersonGenderizerCommand command = new PersonGenderizerCommand();
127-
PersonGenderizerResult result = executor.execute(command, mode, inputPerson).get();
127+
GenderizerResult result = executor.execute(command, mode, inputPerson).get();
128128
```
129129

130130

@@ -150,7 +150,7 @@ The Name Formatter displays personal names in the desired form. This includes th
150150
```java
151151
PersonNameFormatterCommand command = new PersonNameFormatterCommand();
152152
NaturalInputPerson person = new NaturalInputPersonBuilder().name( NameBuilders.western().fullname("john f. kennedy").build() ).build();
153-
FormatterProperties properties = new FormatterPropertiesBuilder().build();
153+
FormatterProperties properties = new FormatterProperties(true);
154154
PersonNameFormatterArgument argument = new PersonNameFormatterArgument(person, properties);
155155
FormatterResult formatterResult = executor.execute(command, mode, argument).get();
156156
```
@@ -172,7 +172,7 @@ The DEA-Detector checks email addresses against a list of known "trash domains"
172172

173173
```java
174174
DisposableEmailAddressDetectorCommand command = new DisposableEmailAddressDetectorCommand();
175-
DisposableEmailAddressDetectorResult result = executor.execute(command, mode, "[email protected]");
175+
DisposableEmailAddressDetectorResult result = executor.execute(command, mode, "[email protected]").get();
176176
```
177177

178178

0 commit comments

Comments
 (0)