I'm trying to setup Google Cloud Messaging between an Android app (Android Studio) and a server. I'm following the directions here: Set up a GCM Client App on Android. The code below is what I've added to my manifest file (as instructed).
<receiver
android:name="com.google.android.gms.gcm.GcmReceiver"
android:exported="true"
android:permission="com.google.android.c2dm.permission.SEND" >
<intent-filter>
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
<category android:name="com.example.gcm" />
</intent-filter>
</receiver>
<service
android:name="com.example.MyGcmListenerService"
android:exported="false" >
<intent-filter>
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
</intent-filter>
</service>
<service
android:name="com.example.MyInstanceIDListenerService"
android:exported="false">
<intent-filter>
<action android:name="com.google.android.gms.iid.InstanceID"/>
</intent-filter>
</service>
This is probably a simple question, but I cannot figure out what com.example.MyGcmListenerService
and com.example.MyInstanceIDListenerService
should be. Android Studio says these symbols are not found. I have not found any help online or on the same instructions page as to what these values should be.
Do these values refer to classes I need to create? Do they refer to something local or remote? I have installed the required SDK components and Cloud Messaging tools (the com.google.android.gms.gcm.GcmReceiver
does get resolved).
Sorry if this is obvious. I am new to Android Studio.