• linux c 头文件


      1 //1.Linux中一些头文件的作用:
      2 #include <assert.h>       //ANSI C。提供断言,assert(表达式) 
      3 #include <glib.h>           //GCC。GTK,GNOME的基础库,提供很多有用的函数,如有数据结构操作函数 
      4 #include <dirent.h>        //GCC。文件夹操作函数 
      5 #include <ctype.h>        //ANSI C。字符测试函数。isdigit(),islower()等 
      6 #include <errno.h>        //ANSI C。查看错误代码errno是调试程序的一个重要方法 
      7 #include <getopt.h>     //处理命令行参数 
      8 
      9 
     10 //2.linux常用头文件如下:
     11 
     12 //POSIX标准定义的头文件 
     13 #include <dirent.h>        //目录项 
     14 #include <fcntl.h>         //文件控制 
     15 #include <fnmatch.h>       //文件名匹配类型 
     16 #include <glob.h>          //路径名模式匹配类型 
     17 #include <grp.h>           //组文件 
     18 #include <netdb.h>         //网络数据库操作 
     19 #include <pwd.h>           //口令文件 
     20 #include <regex.h>           //正则表达式 
     21 #include <tar.h>           //TAR归档值 
     22 #include <termios.h>       //终端I/O 
     23 #include <unistd.h>        //符号常量 
     24 #include <utime.h>         //文件时间 
     25 #include <wordexp.h>       //字符扩展类型 
     26 //————————- 
     27 #include <arpa/inet.h>     //INTERNET定义 
     28 #include <net/if.h>        //套接字本地接口 
     29 #include <netinet/in.h>    //INTERNET地址族 
     30 #include <netinet/tcp.h>   //传输控制协议定义 
     31 //————————- 
     32 #include <sys/mman.h>      //内存管理声明 
     33 #include <sys/select.h>    //Select函数 
     34 #include <sys/socket.h>    //套接字借口 
     35 #include <sys/stat.h>      //文件状态 
     36 #include <sys/times.h>     //进程时间 
     37 #include <sys/types.h>     //基本系统数据类型 
     38 #include <sys/un.h>        //UNIX域套接字定义 
     39 #include <sys/utsname.h>   //系统名 
     40 #include <sys/wait.h>      //进程控制 
     41 //—————————— 
     42 //POSIX定义的XSI扩展头文件 
     43 #include <cpio.h>          //cpio归档值 
     44 #include <dlfcn.h>         //动态链接 
     45 #include <fmtmsg.h>        //消息显示结构 
     46 #include <ftw.h>           //文件树漫游 
     47 #include <iconv.h>         //代码集转换使用程序 
     48 #include <langinfo.h>      //语言信息常量 
     49 #include <libgen.h>        //模式匹配函数定义 
     50 #include <monetary.h>      //货币类型 
     51 #include <ndbm.h>          //数据库操作 
     52 #include <nl_types.h>      //消息类别 
     53 #include <poll.h>          //轮询函数 
     54 #include <search.h>        //搜索表 
     55 #include <strings.h>       //字符串操作 
     56 #include <syslog.h>        //系统出错日志记录 
     57 #include <ucontext.h>      //用户上下文 
     58 #include <ulimit.h>        //用户限制 
     59 #include <utmpx.h>         //用户帐户数据库 
     60 //—————————– 
     61 #include <sys/ipc.h>       //IPC(命名管道) 
     62 #include <sys/msg.h>       //消息队列 
     63 #include <sys/resource.h>  //资源操作 
     64 #include <sys/sem.h>       //信号量 
     65 #include <sys/shm.h>       //共享存储 
     66 #include <sys/statvfs.h>   //文件系统信息 
     67 #include <sys/time.h>      //时间类型 
     68 #include <sys/timeb.h>     //附加的日期和时间定义 
     69 #include <sys/uio.h>       //矢量I/O操作 
     70 //—————————— 
     71 //POSIX定义的可选头文件 
     72 #include <aio.h>           //异步I/O 
     73 #include <mqueue.h>        //消息队列 
     74 #include <pthread.h>       //线程 
     75 #include <sched.h>         //执行调度 
     76 #include <semaphore.h>     //信号量 
     77 #include <spawn.h>         //实时spawn接口 
     78 #include <stropts.h>       //XSI STREAMS接口 
     79 #include <trace.h>         //事件跟踪 
     80 
     81 
     82 //3.C/C++头文件一览:
     83 
     84 //C 
     85 #include <assert.h>    //设定插入点 
     86 #include <ctype.h>     //字符处理 
     87 #include <errno.h>     //定义错误码 
     88 #include <float.h>     //浮点数处理 
     89 #include <iso646.h>        //对应各种运算符的宏 
     90 #include <limits.h>    //定义各种数据类型最值的常量 
     91 #include <locale.h>    //定义本地化C函数 
     92 #include <math.h>     //定义数学函数 
     93 #include <setjmp.h>        //异常处理支持 
     94 #include <signal.h>        //信号机制支持 
     95 #include <stdarg.h>        //不定参数列表支持 
     96 #include <stddef.h>        //常用常量 
     97 #include <stdio.h>     //定义输入/输出函数 
     98 #include <stdlib.h>    //定义杂项函数及内存分配函数 
     99 #include <string.h>    //字符串处理 
    100 #include <time.h>     //定义关于时间的函数 
    101 #include <wchar.h>     //宽字符处理及输入/输出 
    102 #include <wctype.h>    //宽字符分类 
    103  
    104 //传统C++ 
    105 #include <fstream.h>    //改用<fstream> 
    106 #include <iomanip.h>    //改用<iomainip> 
    107 #include <iostream.h>   //改用<iostream> 
    108 #include <strstrea.h>   //该类不再支持,改用<sstream>中的stringstream 
    109 //———————————————————————————————— 
    110  
    111 //标准C++ 
    112 #include <algorithm>    //STL 通用算法 
    113 #include <bitset>     //STL 位集容器 
    114 #include <cctype>          //字符处理 
    115 #include <cerrno>      //定义错误码 
    116 #include <cfloat>     //浮点数处理 
    117 #include <ciso646>         //对应各种运算符的宏 
    118 #include <climits>     //定义各种数据类型最值的常量 
    119 #include <clocale>     //定义本地化函数 
    120 #include <cmath>      //定义数学函数 
    121 #include <complex>     //复数类 
    122 #include <csignal>         //信号机制支持 
    123 #include <csetjmp>         //异常处理支持 
    124 #include <cstdarg>         //不定参数列表支持 
    125 #include <cstddef>         //常用常量 
    126 #include <cstdio>      //定义输入/输出函数 
    127 #include <cstdlib>     //定义杂项函数及内存分配函数 
    128 #include <cstring>     //字符串处理 
    129 #include <ctime>      //定义关于时间的函数 
    130 #include <cwchar>      //宽字符处理及输入/输出 
    131 #include <cwctype>     //宽字符分类 
    132 #include <deque>      //STL 双端队列容器 
    133 #include <exception>    //异常处理类 
    134 #include <fstream>      //文件输入/输出 
    135 #include <functional>   //STL 定义运算函数(代替运算符) 
    136 #include <limits>      //定义各种数据类型最值常量 
    137 #include <list>      //STL 线性列表容器 
    138 #include <locale>          //本地化特定信息 
    139 #include <map>       //STL 映射容器 
    140 #include <memory>          //STL通过分配器进行的内存分配 
    141 #include <new>             //动态内存分配 
    142 #include <numeric>         //STL常用的数字操作 
    143 #include <iomanip>      //参数化输入/输出 
    144 #include <ios>       //基本输入/输出支持 
    145 #include <iosfwd>     //输入/输出系统使用的前置声明 
    146 #include <iostream>     //数据流输入/输出 
    147 #include <istream>     //基本输入流 
    148 #include <iterator>        //STL迭代器 
    149 #include <ostream>     //基本输出流 
    150 #include <queue>      //STL 队列容器 
    151 #include <set>       //STL 集合容器 
    152 #include <sstream>     //基于字符串的流 
    153 #include <stack>      //STL 堆栈容器 
    154 #include <stdexcept>    //标准异常类 
    155 #include <streambuf>    //底层输入/输出支持 
    156 #include <string>     //字符串类 
    157 #include <typeinfo>        //运行期间类型信息 
    158 #include <utility>     //STL 通用模板类 
    159 #include <valarray>        //对包含值的数组的操作 
    160 #include <vector>     //STL 动态数组容器 
    161 //———————————————————————————————— 
    162  
    163 //C99增加的部分 
    164 #include <complex.h>   //复数处理 
    165 #include <fenv.h>    //浮点环境 
    166 #include <inttypes.h>  //整数格式转换 
    167 #include <stdbool.h>   //布尔环境 
    168 #include <stdint.h>   //整型环境 
    169 #include <tgmath.h>   //通用类型数学宏 
    View Code
  • 相关阅读:
    ALINK(十):数据导入与导出 (三)Catalog读入 (CatalogSourceBatchOp)
    ALINK(九):数据导入与导出 (二)Text文件读入 (TextSourceBatchOp)
    ALINK(八):数据导入与导出 (一)CSV文件读入 (CsvSourceBatchOp)
    机器学习sklearn(四): 数据处理(一)数据集拆分(一)train_test_split
    机器学习sklearn(三):加载数据集(数据导入)
    机器学习sklearn(二):SKLEARN快速开始
    机器学习sklearn(一):教程与资料
    程序员的代码的基本素养
    mysql常用函数和语句模式
    BootStrap学习
  • 原文地址:https://www.cnblogs.com/jiaoge/p/4222012.html
Copyright © 2020-2023  润新知