class Observer(ABC): ‘An abstract class for implementing an observer.’
@abstractmethod
def update(self, subject: Any):
'When the subject changes, this method is called to notify the observer.'
pass
class Observer(ABC): ‘An abstract class for implementing an observer.’
@abstractmethod
def update(self, subject: Any):
'When the subject changes, this method is called to notify the observer.'
pass