- 授权协议: 未知
- 开发语言: Java
- 操作系统: Android
- 软件首页: https://github.com/liaohuqiu/android-ActionQueue
软件介绍
ActionQueue 允许你一个一个的执行任务。
导入:
allprojects {
repositories {
mavenCentral()
maven {
url "https://oss.sonatype.org/content/repositories/snapshots"
}
jcenter()
}
}加依赖:
compile 'in.srain.cube:action-queue:1.0.1'
使用
创建 action:
String[] messageList = new String[]{
"message 1",
"message 2",
"message 3",
};
for (int i = 0; i < messageList.length; i++) {
String message = messageList[i];
PopDialogAction action = new PopDialogAction(message);
mActionQueue.add(action);
}处理 action:
class PopDialogAction extends ActionQueue.Action<String> {
public PopDialogAction(String badge) {
super(badge);
}
@Override
public void onAction() {
AlertDialog.Builder builder = new AlertDialog.Builder(MainActivity.this);
Dialog dialog = builder.setMessage(getBadge()).show();
// notify action is done, and next aciton will be executed
dialog.setOnDismissListener(mOnDismissListener);
}
}action 执行完之后通知提醒:
DialogInterface.OnDismissListener mOnDismissListener = new DialogInterface.OnDismissListener() {
@Override
public void onDismiss(DialogInterface dialog) {
mActionQueue.notifyActionDoneThenTryToPopNext();
}
};
计算机程序设计艺术卷1:基本算法(英文版.第3版)
Donald E.Knuth / 人民邮电出版社 / 2010-10 / 119.00元
《计算机程序设计艺术》系列著作对计算机领域产生了深远的影响。这一系列堪称一项浩大的工程,自1962年开始编写,计划出版7卷,目前已经出版了4卷。《美国科学家》杂志曾将这套书与爱因斯坦的《相对论》等书并列称为20世纪最重要的12本物理学著作。目前Knuth正将毕生精力投入到这部史诗性著作的撰写中。想了解本书最新信息,请访http://www-cs-faculty.stanford.edu/~knut......一起来看看 《计算机程序设计艺术卷1:基本算法(英文版.第3版)》 这本书的介绍吧!
