摘要: ####简单说,就是某个系统作为一个服务,对全局系统可见.Service Locator (服务定位)```//简单粗暴的代码, 使用声音系统// Use a static class?AudioSystem::playSound(VERY_LOUD_BANG);// Or maybe a sing... 阅读全文
posted @ 2015-01-21 15:09 summernight 阅读(327) 评论(0) 推荐(0) 编辑
摘要: #### 两个例子1.GUI event loop```while (running){ // 从事件队列里获取一个事件 Event event = getNextEvent(); // Handle event...}```2.Central event bus 不同系统公用的通信中心... 阅读全文
posted @ 2015-01-21 13:31 summernight 阅读(336) 评论(0) 推荐(0) 编辑