Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrBadPattern = errors.New("Invalid pattern")
ErrBadPattern indicates a globbing pattern was malformed.
Functions ¶
func Match ¶
Match reports whether name matches the shell file name pattern. The pattern syntax is:
pattern: { term } term: '**' matches any sequence of characters '*' matches any sequence of non-/ characters '?' matches any single non-/ character '[' [ '^' ] { character-range } ']' character class (must be non-empty) c matches character c (c != '*', '?', '\\', '[') '\\' c matches character c character-range: c matches character c (c != '\\', '-', ']') '\\' c matches character c lo '-' hi matches character c for lo <= c <= hi
Match requires pattern to match all of name, not just a substring. The only possible returned error is ErrBadPattern, when pattern is malformed.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.