Join Christopher Anatalio for an in-depth discussion in this video Create Printer actor, part of Reactive Programming with Java 8.
- [Instructor] The last actor we need to create…is the printerActor.…Let's go ahead and create a new class called Printer.…Let's extend the AbstractActor…and use the keyboard shortcut alt plus enter.…Then let's implement the createReceive method.…
Let's create a new r constructor…using the keyboard shortcut command n.…Then let's create our Props method.…Let's create our props, passing in the printer class…and a lambda which returns a new instance of printer.…
Now let's define the message class CryptoPrice.…We are gonna declare one field,…a mono of the type CoinBaseResponse.…If you can recall, a mono of the type CoinBaseResponse…is what the getCryptoPrice method returns…in the class CoinbaseServiceImpl.…
Now let's generate a constructor.…Finally, let's define the createReceive method.…Let's call receiveBuilder…and have I match on the CryptoPrice message.…Now let's pass in a lambda that takes in a single parameter.…Let's grab the mono from the CryptoPrice message…and then subscribe to it.…
When that request completes we will print out the output.…
- Reactive programming concepts and techniques
- Functional programming concepts and techniques
- Overview of popular reactive frameworks
- Building an RxJava application
- Building an Akka application
- Unit testing with Akka and RxJava
Skill Level Intermediate
1. Reactive Programming
2. Functional Programming
3. Survey of Reactive Frameworks
4. ReactiveX and RxJava
6. Unit Testing
Unit testing with Akka1m 52s
Next steps1m 19s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.