So I'm making an iOS app where users can send/receive messages to/from other random user but I'm trying to figure out what will be the most efficient way to implement it with these conditions and using Parse.com:
- If user hasn't received any message for 24 hours automatically retrieve one from the server
- The user has more possibilities of receive a message for each message he sends
I was thinking on do it this way:
1 - Making a new class "X" where users are added once they have sent a message, this message will be sent to a user already in that class "X" and the user will be removed from the class once he received it.
2 - To make the user receive a message every 24 hours - Set a portion of code that is executed every 24hours and adds the user to class "X" so he has the possibility to receive a message.
Aucun commentaire:
Enregistrer un commentaire