博客
关于我
unix环境编程 目录操作
阅读量:225 次
发布时间:2019-02-28

本文共 809 字,大约阅读时间需要 2 分钟。

???????POSIX???????????????????????????????????????

1. ??????

  • *mkdir(const char pathname, mode_t mode)

    ?????????0??????-1?

  • *rmdir(const char pathname)

    ??????????0??????-1?

  • **DIR opendir(const char pathname)

    ?????????DIR????????NULL?

  • **struct dirent readdir(DIR dp)

    ???????????????????struct dirent????????NULL?

  • *void rewinddir(DIR dp)

    ?????????????????0??????-1?

  • *int closedir(DIR dp)

    ?????????0??????-1?

  • *int chdir(const char pathname)

    ???????????0??????-1?

  • **char getcwd(char buf, size_t size)

    ?????????????buf??????NULL?

2. ?????????????

????????????????????????

  • ??opendir?????????DIR???
  • ??readdir???????????????
  • ????????????????????
  • 3. ?????

    ??????ls *.txt???????????????????????popen?pclose?????????????????

    4. ?????

    popen?pclose??????????fork??????????????????????

    ?????????????????????????? POSIX ?????

    转载地址:http://lmwp.baihongyu.com/

    你可能感兴趣的文章
    Objective-C实现harmonic series调和级数算法(附完整源码)
    查看>>
    Objective-C实现harris算法(附完整源码)
    查看>>
    Objective-C实现HashTable哈希表算法(附完整源码)
    查看>>
    Objective-C实现haversine distance斜距算法(附完整源码)
    查看>>
    Objective-C实现heap sort堆排序算法(附完整源码)
    查看>>
    Objective-C实现heaps algorithm堆算法(附完整源码)
    查看>>
    Objective-C实现heap堆算法(附完整源码)
    查看>>
    Objective-C实现Heap堆算法(附完整源码)
    查看>>
    Objective-C实现hexagonal numbers六边形数算法(附完整源码)
    查看>>
    Objective-C实现hidden layers neural network浅层神经网络算法(附完整源码)
    查看>>
    Objective-C实现highest response ratio next高响应比优先调度算法(附完整源码)
    查看>>
    Objective-C实现hill climbing爬山法用来寻找函数的最大值算法(附完整源码)
    查看>>
    Objective-C实现histogram stretch直方图拉伸算法(附完整源码)
    查看>>
    Objective-C实现Hopcroft算法(附完整源码)
    查看>>
    Objective-C实现horizontal projectile motion平抛运动算法(附完整源码)
    查看>>
    Objective-C实现hornerMethod霍纳法算法(附完整源码)
    查看>>
    Objective-C实现Horn–Schunck光流算法(附完整源码)
    查看>>
    Objective-C实现Http Post请求(附完整源码)
    查看>>
    Objective-C实现http下载文件 (附完整源码)
    查看>>
    Objective-C实现Http协议下载文件(附完整源码)
    查看>>