來源自 這裡
Preface :
This module provides support for Unix shell-style wildcards, which are not the same as regular expressions (which are documented in the re module). The special characters used in shell-style wildcards are :

Note that the filename separator ('/' on Unix) is not special to this module. See module glob for pathname expansion (glob uses fnmatch() to match pathname segments). Similarly, filenames starting with a period are not special for this module, and are matched by the * and ? patterns.
Supported APIs :
- fnmatch.fnmatch(filename, pattern)
- fnmatch.fnmatchcase(filename, pattern)
- fnmatch.filter(names, pattern)
- fnmatch.translate(pattern)
Preface :
This module provides support for Unix shell-style wildcards, which are not the same as regular expressions (which are documented in the re module). The special characters used in shell-style wildcards are :
Note that the filename separator ('/' on Unix) is not special to this module. See module glob for pathname expansion (glob uses fnmatch() to match pathname segments). Similarly, filenames starting with a period are not special for this module, and are matched by the * and ? patterns.
Supported APIs :
- fnmatch.fnmatch(filename, pattern)
- fnmatch.fnmatchcase(filename, pattern)
- fnmatch.filter(names, pattern)
- fnmatch.translate(pattern)
This message was edited 6 times. Last update was at 11/05/2012 13:18:15
沒有留言:
張貼留言