Created
          March 24, 2014 15:30 
        
      - 
      
- 
        Save guilhermecarvalhocarneiro/9742501 to your computer and use it in GitHub Desktop. 
    BroadCastReceiver GCM
  
        
  
    
      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
    
  
  
    
  | public class MessageBroadCast extends BroadcastReceiver { | |
| String tag = "Mensagem"; | |
| @Override | |
| public void onReceive(Context context, Intent intent) { | |
| Bundle extras = intent.getExtras(); | |
| try { | |
| if(extras != null){ | |
| Log.i(tag, "Mensagem" + extras.getString("param1", "Nada")); | |
| } | |
| } catch (Exception e) { | |
| Log.e("Mensagem Erro", e.toString()); | |
| } | |
| } | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment