Android Looper和Handler分析(5)
来源:未知 责任编辑:责任编辑 发表时间:2014-04-20 03:36 点击:次
pw.println(prefix + this);
pw.println(prefix + "mRun=" + mRun);
pw.println(prefix + "mThread=" + mThread);
pw.println(prefix + "mQueue=" + ((mQueue != null) ? mQueue : "(null"));
if (mQueue != null) {
synchronized (mQueue) {
Message msg = mQueue.mMessages;
int n = 0;
while (msg != null) {
pw.println(prefix + " Message " + n + ": " + msg);
n++;
msg = msg.next;
}
pw.println(prefix + "(Total messages: " + n + ")");
}
}
}
public String toString() {
return "Looper{"
+ Integer.toHexString(System.identityHashCode(this))
+ "}";
}
static class HandlerException extends Exception {
HandlerException(Message message, Throwable cause) {
super(createMessage(cause), cause);
}
static String createMessage(Throwable cause) {
String causeMsg = cause.getMessage();
if (causeMsg == null) {
相关新闻>>
最新推荐更多>>>
- 发表评论
-
- 最新评论 更多>>