[Up] |
Reference for unit 'Wildcrds' (#Pkg) |
Pattern Format
A pattern can contains :
- '*' to match any sequence of zero or more characters
- '?' to match any single character
- a set to match any character that is part of the set (see above)
- '\D' to match ['0'..'9']
- '\L' to match ['a'..'z']
- '\U' to match ['A'..'Z']
- '\A' to match ['a'..'z', 'A'..'Z']
- '\0' to match #0
- '\a' to match #7
- '\b' to match #8
- '\t' to match #9
- '\n' to match #10
- '\v' to match #11
- '\f' to match #12
- '\r' to match #13
- '\?' to match '?'
- '\*' to match '*'
- '\!' to match '!'
- '\-' to match '-'
- '\\' to match '\'
Sets
A set is a list of characters surrounded by square brakets. For example the set [ab] matches 'a' or 'b'. In addition two characters separated by '-' denote a range. Thus [a-f0-9] is equivalent to [abcdef0123456789]. A set can be complemented if it starts with '!'. Thus [!ab] matches any character except a and b.