Wildcard expansion is the process of pattern matching by treating a special wildcard character as a replaceable segment of the pattern.
Wildcard expansion, or globbing in a UNIX context, is a common technique of extracting a set of values that match a simple pattern. The wildcard character stands in for a sequence of potentially variable character that the pattern is not concerned with.
Wildcards typically use the following characters: ?
, *
, or %
.
Depending on the context these can mean different things, but typically ?
matches a single character, and *
or %
match zero or more characters. The specific set wildcard characters accepted vary with the application.
Wildcard expansion is related to regular expressions but should not be confused with them as they are very distinct entities.