title: Is it possible to define a broadcast receiver as an inner class in manifest file?
body: <p>I want to create a broadcast receiver as an inner class in my main activity. 
  But I have problems defining the broadcast receiver in manifest xml file,
  because android can't find it.</p>
  
  <p>Code:</p>
  
  <pre><code>public class MyActivity extends Activity{
      ...
  
      public class Receiver extends BroadcastReceiver{
  
          @Override
          public void onReceive(Context context, Intent intent) {
              ....
          }
  
      }
  
      ...
  }
  </code></pre>
  
  <p>Manifest:</p>
  
  <pre><code>&lt;receiver android:name=".org.danizmax.myapp.MyActivity$Receiver" android:enabled="true"&gt;
              &lt;intent-filter&gt;
                  &lt;action android:name="org.danizmax.myapp.BROADCAST_INITIAL_DATA"&gt;&lt;/action&gt;
              &lt;/intent-filter&gt;
  &lt;/receiver&gt;
  </code></pre>
  
  <p>I tried with:</p>
  
  <ul>
  <li>.org.danizmax.myapp.MyActivity$Receiver</li>
  <li>org.danizmax.myapp.MyActivity$Receiver</li>
  <li>.MyActivity$Receiver </li>
  <li>.Receiver</li>
  </ul>
  
  <p>I saw others also having similar problems, but did not find any answers.</p>
  
  <p>So is it possible? If not, what's better way to use broadcast receivers?</p>
  
  <p>Thanks!</p>