摘要: http://www.cnblogs.com/pluviophile/p/7542017.html,看了这篇博文感觉这个例子有用遂搬运过来方便查阅 上面的类图就体现了所需要了解的类的6个基本关系 该类图中车是一个抽象类 车有两个继承,小汽车和自行车,他们和车之间是实现关系,使用带空心箭头的虚线表示 阅读全文
posted @ 2017-09-21 22:58 木白木又寸 阅读(152) 评论(0) 推荐(0) 编辑
摘要: 1 int buffer_append_long_hex(buffer *b, unsigned long value) { 2 char *buf; 3 int shift = 0; 4 unsigned long copy = value; 5 6 while (copy) { 7 copy > 阅读全文
posted @ 2016-03-06 23:18 木白木又寸 阅读(887) 评论(0) 推荐(0) 编辑
摘要: ZeroMq实现跨线程通信之前在技术崇拜的技术经理指导下阅读了ZeroMq的基础代码,现在就将阅读的心得与成果记录一下,并重新模仿实现了一下经理的异步队列。1、对外接口//主要接口(1)void *ymq_attach (void *ctx_, int oid, void* sink_);(2)v... 阅读全文
posted @ 2015-11-04 22:55 木白木又寸 阅读(740) 评论(0) 推荐(0) 编辑
摘要: //QT += core gui opengl//LIBS += -losgViewer -losgDB -losgUtil -losg -lOpenThreads -losgGA -losgQt#include #include #include #include #include #in... 阅读全文
posted @ 2015-07-29 22:59 木白木又寸 阅读(3915) 评论(0) 推荐(0) 编辑
摘要: 1 #ifndef MUTEX_CLASS_H 2 #define MUTEX_CLASS_H 3 4 class mutex_class 5 { 6 public: 7 mutex_class(); 8 void lock(); 9 void unlock();10 1... 阅读全文
posted @ 2015-05-06 21:43 木白木又寸 阅读(183) 评论(0) 推荐(0) 编辑
摘要: 1 void getPoint(QwtPlot *plot)2 {3 QPoint point = plot->canvas()->mapFromGlobal(QCursor::pos()); 4 QString info.sprintf("x = %g, y = %g"... 阅读全文
posted @ 2014-12-06 20:30 木白木又寸 阅读(1327) 评论(0) 推荐(0) 编辑
摘要: 一:操作系统0、解释一下僵尸进程是怎么产生的,然后怎么回收的。用什么命令可以查看当前所有的僵尸进程1. 进程的有哪几种状态,状态转换图,及导致转换的事件。2. 进程与线程的区别。3. 进程通信的几种方式。4. 线程同步几种方式。(一定要会写生产者、消费者问题,完全消化理解)5. 线程的实现方式. (... 阅读全文
posted @ 2014-11-15 12:46 木白木又寸 阅读(261) 评论(0) 推荐(0) 编辑
摘要: 初步的界面如下:为了实现不同的窗口、不同进程弈五子棋对弈,就需要在不同进程间的进行通信,我们采用linux底层的命名管道进行通信。首先我们要进行管道通信头文件的包含、传输数据的结构定义、数据通信操作的函数定义(代码如下): 1 #ifndef MESGOPREAT_H 2 #define MESGO... 阅读全文
posted @ 2014-08-19 21:03 木白木又寸 阅读(432) 评论(0) 推荐(0) 编辑
摘要: A new way of thinking has become the necessary condition for responsible living and acting. If you want to move forward, you must change your way of thinking and leave these thoughts behind you:负责任的生活和行为方式需要新的思维方式。如果你想要继续前行,你就必须改变思维方式,把这10种想法抛在脑后:1. “I don’t have a choice.”我别无选择。You write your own d 阅读全文
posted @ 2013-02-21 15:58 木白木又寸 阅读(175) 评论(0) 推荐(0) 编辑