January 2020
Intermediate to advanced
532 pages
13h 31m
English
The observer pattern is useful for registering observers to an object so that all state changes in that object trigger the sending of notifications to the observers. In a language that supports first-class functions—for example, Julia—such functionality can be implemented easily by maintaining a list of functions that can be called before or after the state changes of an object. Sometimes, these functions are called hooks.
The implementation of the observer pattern in Julia may consist of two parts:
For this demonstration, we will bring up the bank account ...
Read now
Unlock full access