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

Split up process_next_message() to facilitate overriding. #48

Merged
merged 1 commit into from Jul 13, 2015

Conversation

mertemba
Copy link
Collaborator

Currently, to handle messages of custom format, peers inheriting from Peer_DBS have to copy the process_next_message(self) method and adapt it to new messages.
With this change, inheriting peers can override the process_message(self, message, sender) method and implement their case differentiation. In case the inheriting class does not handle the received message, the base class method can be called.

vicente-gonzalez-ruiz pushed a commit that referenced this pull request Jul 13, 2015
Split up process_next_message() to facilitate overriding.
@vicente-gonzalez-ruiz vicente-gonzalez-ruiz merged commit 18e754b into P2PSP:master Jul 13, 2015
@vicente-gonzalez-ruiz
Copy link
Member

Thanks (again).

mertemba added a commit to mertemba/p2psp that referenced this pull request Jul 13, 2015
vicente-gonzalez-ruiz pushed a commit that referenced this pull request Jul 13, 2015
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

2 participants