Application Of Observer Design Pattern

Application Of Observer Design Pattern

Let us now look in to the application of observer design patterns. Observer design patterns are extensively used in communication networks. The Publish/Subscribe [PUB-SUB] messaging model of the asynchronous communication is an excellent application of Observer design pattern.

Walkie Talkies use the same pattern for facilitating communication between groups of people wherein the hansets [TransRecievers] are the observers while the frequencies are the topics. Whenever a group of individuals need to communicate, they tune their handsets to a particular frequency and then they all can communicate using that particular frequency.

BroadCasts are also an excellent example of Observers.

Radio and Television broadcasts are also variants of this pattern with an exception that we cannot publish using the receivers.

In software systems as well, observer design patterns have wide range of applications.

One of the common applications is where a common set of data has to be shown in three different views keeping the views synchronized ie changes in one view should be updated across all the views.

The figure below shows the same

Figure- Figure

Hemant Jha
Founder - VPlanSolutions
Researcher, Trainer