I am new in the Java Android world. I am working on a course project and I need some help. In my project I have developed an Android app and a Java Socket Server. Android App requests for Keys from Server and server generates keys, Stores them in its DB and sends keys back to android client. This is working fine. Now, in android client, I have to add a button called "Register Device" and on click this should register device with GCM and store the regID in device, which I want to add with keys request and send to server. Server will store the regID in DB with the keys. Then later I want to send a push message to device using that stored regID.
Problems:
- How can I store and then access GCM regID to send to server?
- What needs to be done in my Socket Server to send push messages to device using stored regID?