Skip to content

Adding Proxy Design Pattern #1178

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

Merged
merged 3 commits into from
Nov 28, 2019
Merged

Conversation

ali4j
Copy link

@ali4j ali4j commented Nov 27, 2019

I decided to add a simple and clear example to demonstrate the proxy design pattern. Here is the summary of the changes:
The President class is a class which gets proxied by PresidentSecretary class. So whenever a Citizen (actually the test class) tries to contact the President, they have to talk to the Secretary.
In this way the secretary can log the messages and also checks the messages and ignores invalid ( too long) ones.

@yanglbme yanglbme merged commit 6ad2c9f into TheAlgorithms:Development Nov 28, 2019
changes messages printed by the secretary and the president.
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.

2 participants