The thing that needs to be refactored is called the Observer Pattern, and it's one of GoF patterns that most professional programmers should at least know about.
By "know", I mean the mere fact that it exists. Implementation details depend on the programming language and can always be looked up.
By "know", I mean the mere fact that it exists. Implementation details depend on the programming language and can always be looked up.