Basic SMS messages structure#4
Open
EnricoCestaro wants to merge 1 commit into
Open
Conversation
This reverts commit 98330bc.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Premise
In this pull request, we are proposing the SMS implementation of the more generic Commands that we presented in the previous pull request.
We also completed the first version of the SMSJoinableNetManager, the class that allows the user to decide to enter a network when invited; it extends the more basic SMSNetworkManager class.
An interesting class to analyze is the RequestType, a modified enum used to recognize the incoming SMS messages.
The BroadcastSender, a small class to send messages to all the specified peers.
And a bunch of tests, just to prove you that we are doing them.
Main changes
1. SMSJoinableNetManager
This class is triggered by a listener, if activated the network asks the user if he prefers to enter a specific network or not
2. "SMSCommands"
. SMSAcceptInvite
. SMSInvitePeer
. SMSAddPeer
. SMSAddResource
. SMSRemovePeer
. SMSRemoveResource
The SMS implementation of the more basic Commands of the previous Pull Request,
What is left to do
We have to finish the BroadcastReceiver (the SMS messages listener that decode their content) and connect everything.
Non of these classes can be classified as completed, according to your opinion we will decide how to proceed, please let us know if there is some major problem that we missed.
We hope that, without considering the tests, this won't appear as too much code to review, it's pretty modular and a lot of classes shares the same simple structure.
Thank you, and good review.