摘要: 1 采用异步设计 假设使用同步实现,伪装代码如下: Transfer(accountFrom, accountTo, amount) { // 先从 accountFrom 的账户中减去相应的钱数 Add(accountFrom, -1 * amount) // 再把减去的钱数加到 accountT 阅读全文
posted @ 2020-12-15 21:30 hongxinerke 阅读(248) 评论(0) 推荐(0) 编辑