Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First Behavioral Design Pattern (Observer Design Pattern) #170

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

SwithinTan
Copy link

@SwithinTan SwithinTan commented Apr 20, 2021

Description: Two interfaces Subject, Observer, and its correspondent concrete class ConcreteObserver that extending class Observer were created in a new separate observer.py. The Subject interface declares a set of methods for managing subscribers, including attach, detach and notify to a client object.
MSTranslator functions to translate the questions and answers in English into another language and write them in a csv file which will be observed by our Observer.
Also, observer Design Pattern follows Open-closed principle, so new subscriber objects can be easily introduced while keep publisher code unchanged. Subscriber lists can be customized freely.

@SwithinTan SwithinTan changed the title PR1 PR3 Apr 20, 2021
@SwithinTan SwithinTan changed the title PR3 First Behavioral Design Pattern (Observer Design Pattern) Apr 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant