多路复用 select 同时监控多个文件描述符的输入输出 <sys/types.h> <sys/times.h> <sys/select.h> int select(int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds, str ...
分类:
其他好文 时间:
2018-06-23 01:24:34
阅读次数:
144
首先需要了解的是select函数: select函数 #include<sys/select.h> #include<sys/time.h> int select (int maxfd , fd_set *readset ,fd_set *writeset, fd_set *exceptionset ...
分类:
其他好文 时间:
2018-04-29 23:14:13
阅读次数:
218
1、先看man手册 SYNOPSIS /* According to POSIX.1-2001 */ #include <sys/select.h> /* According to earlier standards */ #include <sys/time.h> #include <sys/ty ...
分类:
系统相关 时间:
2017-12-22 22:49:56
阅读次数:
277
//ser.cpp #include <iostream> #include <fcntl.h> #include <sys/socket.h> #include <sys/select.h> #include <unistd.h> #include <arpa/inet.h> #include < ...
分类:
系统相关 时间:
2017-07-17 17:17:39
阅读次数:
148
1. 什么是表分区? 表分区,是指根据一定规则,将数据库中的一张表分解成多个更小的,容易管理的部分。从逻辑上看,只有一张表,但是底层却是由多个物理分区组成。 2. 表分区与分表的区别 分表:指的是通过一定规则,将一张表分解成多张不同的表。比如将用户订单记录根据时间成多个表。 分表与分区的区别在于:分 ...
分类:
数据库 时间:
2017-06-13 16:40:34
阅读次数:
256
函数原型 /* According to POSIX.1-2001 */ #include <sys/select.h> //头文件 /* According to earlier standards */ #include <sys/time.h> #include <sys/types.h> # ...
分类:
系统相关 时间:
2017-06-02 21:14:08
阅读次数:
400
近期看到好多人在问。c/c++中的sleep函数是秒级的,能不能实现毫秒级的呢?当然非常easy。我的写法例如以下 #include <stdio.h> #include <sys/select.h> static void sleep_ms(unsigned int secs) { struct ...
分类:
编程语言 时间:
2017-05-25 23:38:36
阅读次数:
309
计划 估计此程序需要3-5天。 开发 需求分析 用户故事:作为一个观众,我希望了解某一场比赛的比分,以便了解赛况。(满意条件:精确到每一局的结果比分)。 从分析用例故事可以知道完成此程序需要这两项任务:选择队伍和查询比赛记录。 以下为改程序的活动图: 代码规范:使用Vs2010和帕斯卡命名法和骆驼命 ...
分类:
其他好文 时间:
2016-12-24 02:34:56
阅读次数:
228
SELECT qyv.* FROM (select ROW_NUMBER() OVER(PARTITION BY 1 order by cust_party_id DESC) rn, h.* FROM cop_customer_header_v h where 1 = 1 and TRUNC(SYS ...
分类:
数据库 时间:
2016-11-07 17:41:30
阅读次数:
245
#include <sys/select.h> #include <sys/time.h> #include <sys/types.h> #include <unistd.h> int select(int nfds, fd_set * readfds, fd_set * writefds, fd_ ...
分类:
其他好文 时间:
2016-06-06 10:28:10
阅读次数:
219