/**
 * Implements a thread-local storage, that is, a variable for which each thread
 * has its own value. All threads share the same {
@code ThreadLocal} object,
 * but each sees a different value when accessing it, and changes made by one
 * thread do not affect the other threads. The implementation supports
 * {
@code null} values.
 *
 *
@see java.lang.Thread
 *
@author Bob Lee
 */
public class ThreadLocal<T>

/**
  * Class used to run a message loop for a thread.  Threads by default do
  * not have a message loop associated with them; to create one, call
  * {
@link #prepare} in the thread that is to run the loop, and then
  * {
@link #loop} to have it process messages until the loop is stopped.

public final class Looper

/**
 *
 * Defines a message containing a description and arbitrary data object that can be
 * sent to a {
@link Handler}.  This object contains two extra int fields and an
 * extra object field that allow you to not do allocations in many cases. 
 *
 *
While the constructor of Message is public, the best way to get
 * one of these is to call {
@link #obtain Message.obtain()} or one of the
 * {
@link Handler#obtainMessage Handler.obtainMessage()} methods, which will pull
 * them from a pool of recycled objects.
</p>
 */
public final class Message implements Parcelable

/**
 * Low-level class holding the list of messages to be dispatched by a
 * {
@link Looper}.  Messages are not added directly to a MessageQueue,
 * but rather through {
@link Handler} objects associated with the Looper.
 *
 *
<p>You can retrieve the MessageQueue for the current thread with
 * {
@link Looper#myQueue() Looper.myQueue()}.
 */
public final class MessageQueue

/**
 * A Handler allows you to send and process {
@link Message} and Runnable
 * objects associated with a thread's {
@link MessageQueue}.  Each Handler
 * instance is associated with a single thread and that thread's message
 * queue.  When you create a new Handler, it is bound to the thread /
 * message queue of the thread that is creating it -- from that point on,
 * it will deliver messages and runnables to that message queue and execute
 * them as they come out of the message queue.

public class Handler

MessageQueue 相关概念的更多相关文章

  1. Android消息处理机制(Handler、Looper、MessageQueue与Message)

    Android是消息驱动的,实现消息驱动有几个要素: 消息的表示:Message 消息队列:MessageQueue 消息循环,用于循环取出消息进行处理:Looper 消息处理,消息循环从消息队列中取 ...

  2. IDDD 实现领域驱动设计-上下文映射图及其相关概念

    上一篇:<IDDD 实现领域驱动设计-理解限界上下文> 距离上一篇有几天时间了,<实现领域驱动设计>第三章的内容都是围绕一个词-上下文映射图,我大概断断续续看了几天,总共看了两 ...

  3. 微软 消息队列 MessageQueue 简单使用

    1.在服务电脑上打开 消息队列 ①进入控制面板>程序>启用或关闭windows功能 ②将需要的勾选(我自己全选了哈哈哈) ③我的电脑 右键 打开管理 见到消息队列 在专用队列上新建专用队列 ...

  4. [原创]java WEB学习笔记105:Spring学习---AOP介绍,相关概念,使用AOP,利用 方法签名 编写 AspectJ 切入点表达式

    本博客的目的:①总结自己的学习过程,相当于学习笔记 ②将自己的经验分享给大家,相互学习,互相交流,不可商用 内容难免出现问题,欢迎指正,交流,探讨,可以留言,也可以通过以下方式联系. 本人互联网技术爱 ...

  5. Handler+ExecutorService(线程池)+MessageQueue模式+缓存模式

    android线程池的理解,晚上在家无事 预习了一下android异步加载的例子,也学习到了一个很重要的东东 那就是线程池+缓存  下面看他们的理解.[size=1.8em]Handler+Runna ...

  6. (转)Android消息处理机制(Handler、Looper、MessageQueue与Message)

    转自 http://www.cnblogs.com/angeldevil/p/3340644.html Android消息处理机制(Handler.Looper.MessageQueue与Messag ...

  7. Android多线程分析之四:MessageQueue的实现

    Android多线程分析之四:MessageQueue的实现 罗朝辉 (http://www.cnblogs.com/kesalin/) CC 许可,转载请注明出处 在前面两篇文章<Androi ...

  8. C#并行编程-相关概念

    菜鸟初步学习,不对的地方请大神指教,参考<C#并行编程高级教程.pdf> 目录 C#并行编程-相关概念 C#并行编程-Parallel C#并行编程-Task C#并行编程-并发集合 C# ...

  9. 讲讲Handler+Looper+MessageQueue 关系

    Handler+Looper+MessageQueue这三者的关系其实就是Android的消息机制.这块内容相比开发人员都不陌生,在面试中,或者日常开发中都会碰到,今天就来讲这三者的关系. 概述: H ...

随机推荐

  1. 实现text-detection-ctpn一路的坎坎坷坷

    小编在学习文字检测,因为作者提供的caffe实现没有训练代码(不过训练代码可以参考faster-rcnn的训练代码),所以我打算先使用tensorflow实现,主要是复现前辈的代码,主要是对文字检测模 ...

  2. angularjs学习第六天笔记(指令简介学习)

    您好,由于周末有事情,没哟学习angularjs,几天晚上开始继续学习angularjs,坚持加油每一天.谢谢 接着上周五学习了表单验证以后,今天开始学习angularjs中一个非常重要的模块:指令 ...

  3. C# 类相同属性赋值

    做项目时偶尔B类赋值给A类,碰巧A和B类型很多属性字段名是一样的,或者只是大小写不一样,这是可以利用泛型,反射来写一个自动化赋值的方法. 下面方法不考虑大小写不一样的情况,如果要考虑,可以使用字符串方 ...

  4. Nullable<System.DateTime>日期格式转换 (转载)

    一.问题 1.html页面中时间显示出错,数据库中时间是正确的. 原因:没有把DateTime转成String类型. 2.  在C#中,发现不能直接使用ToString("yyyy-MM-d ...

  5. [PHP] 算法-镜像二叉树的PHP实现

    操作给定的二叉树,将其变换为源二叉树的镜像. 二叉树的镜像定义:源二叉树 8 / \ 6 10 / \ / \ 5 7 9 11 镜像二叉树 8 / \ 10 6 / \ / \ 11 9 7 5 思 ...

  6. CSS学习笔记09 简单理解BFC

    引子 在讲BFC之前,先来看看一个例子 <!DOCTYPE html> <html lang="en"> <head> <meta cha ...

  7. 将javaWeb项目转maven项目

    不经常做此类转换,所以总是忘记转换方法,特此,记录下转换步骤 1.首先从SVN检出项目 2.找到导出项目路径 3.按住Shift+鼠标右键,打开控制台 3.输入命令mvn eclipse:eclips ...

  8. PHP7.27: MySqlhelper class

    https://github.com/ThingEngineer/PHP-MySQLi-Database-Class https://github.com/wildantea/php-pdo-mysq ...

  9. sql script: Graphs, Trees, Hierarchies and Recursive Queries

    --------------------------------------------------------------------- -- Inside Microsoft SQL Server ...

  10. numpy库的常用方法

    np.abs() 计算数组各元素的绝对值1 a= [0,1,2,3,4,-5,9,-3,12,-4] np.abs(a)out: array([ 0, 1, 2, 3, 4, 5, 9, 3, 12, ...