Cisco Reg. Expression |
Regular Expression
^ Regular Expression
Use this to look for text at the beginning of a string.
$ Regular Expression:
Use this to look for text at the end of a string
. Regular Expression:
The "." matches any single character.
_ Regular Expression:
This replaces a long regular expression list by matching a comma (,), left brace ({),
right brace (}), the beginning of the input string, the end of the input string, or a space.
[ ] Regular Expression:
This matches the characters or a range of characters separated by a hyphen, within left and right square brackets.
[02468w] matches for example 0, 4, and w, but not 1, 9, or K
| Regular Expression:
Use the | as a logical or statement.
Matches one of the characters or character patterns on either side of the vertical bar.
A(B|C)D matches ABD and ACD, but not AD, ABCD, ABBD, or ACCD
\ Regular Expression:
Use this if the following character is not a wildcard, but an actual character you are looking for.
? Regular Expression:
This matches zero or one occurrence of the pattern. (Remember to precede the question mark with Ctrl-V sequence to
prevent it from being interpreted as a help command.)ba?b matches bb and bab
+ Regular Expression:
This matches one or more sequences of the character preceding the plus sign.
5+ requires there to be at least one number 5 in the string to be matched
[] Regular Expression:
Nest characters for matching. Separate endpoints of a range with a dash (-).
(18)* matches any number of the two-character string 18
([A-Za-z][0-9])+ matches one or more instances of letter-digit pairs: b8 and W4, as examples
* Regular Expression:
Matches zero or more sequences of the character preceding the asterisk. Also acts as a wildcard for matching
any number of characters.0* matches any occurrence of the number 0 including none
|
|