This documentation is archived and is not being maintained.
Regex Methods
Visual Studio 2008
The Regex type exposes the following members.
| Name | Description | |
|---|---|---|
|
CompileToAssembly | Overloaded. Compiles regular expressions and saves them to disk in a single assembly. |
|
Equals | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
|
Escape | Escapes a minimal set of characters (\, *, +, ?, |, {, [, (,), ^, $,., #, and white space) by replacing them with their escape codes. This instructs the regular expression engine to interpret these characters literally rather than as metacharacters. |
|
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) |
|
GetGroupNames | Returns an array of capturing group names for the regular expression. |
|
GetGroupNumbers | Returns an array of capturing group numbers that correspond to group names in an array. |
|
GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
|
GetType | Gets the type of the current instance. (Inherited from Object.) |
|
GroupNameFromNumber | Returns the group name that corresponds to the specified group number. |
|
GroupNumberFromName | Returns the group number that corresponds to the specified group name. |
|
InitializeReferences | Infrastructure. Used by a Regex object generated by the CompileToAssembly method. |
|
IsMatch | Overloaded. Indicates whether the regular expression finds a match in the input string. |
|
Match | Overloaded. Searches an input string for a substring that matches a regular expression pattern and returns the first occurrence as a single Match object. |
|
Matches | Overloaded. Searches an input string for all occurrences of a regular expression and returns all the successful matches. |
|
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
|
Replace | Overloaded. Within a specified input string, replaces strings that match a regular expression pattern with a specified replacement string. |
|
Split | Overloaded. Splits an input string into an array of substrings at the positions defined by a regular expression match. |
|
ToString | Returns the regular expression pattern that was passed into the Regex constructor. (Overrides Object.ToString.) |
|
Unescape | Converts any escaped characters in the input string. |
|
UseOptionC | Infrastructure. Used by a Regex object generated by the CompileToAssembly method. |
|
UseOptionR | Infrastructure. Used by a Regex object generated by the CompileToAssembly method. |
| Name | Description | |
|---|---|---|
|
ISerializable.GetObjectData | Infrastructure. Populates a SerializationInfo object with the data necessary to deserialize the current Regex object. |
Show: