标签:can tail anti oid tde 需要 instant color example
广播的定义,如果是内部类,必须为静态类
http://blog.csdn.net/chdjj/article/details/19496567
android:name="com.example.brocastdemo.MainActivity$MyReceiver"
2.内部类在声明时一定要写成静态内部类(class关键字前加上static)。否则会抛出类似这样的异常:
02-19 09:11:14.650: E/AndroidRuntime(1771): java.lang.RuntimeException: Unable to instantiate receiver com.example.brocastdemo.MainActivity$MyReceiver: java.lang.InstantiationException: can‘t instantiate class com.example.brocastdemo.MainActivity$MyReceiver; no empty constructor
Android广播错误.MainActivity$MyReceiver; no empty constructor
标签:can tail anti oid tde 需要 instant color example
原文地址:http://www.cnblogs.com/zhujiabin/p/7499246.html