mscorlib(4.0.0.0) API with additions
|
Implements a set of methods for culture-sensitive string comparisons. More...
Public Member Functions | |
virtual int | Compare (string string1, string string2) |
Compares two strings. More... | |
virtual int | Compare (string string1, string string2, CompareOptions options) |
Compares two strings using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | Compare (string string1, int offset1, int length1, string string2, int offset2, int length2) |
Compares a section of one string with a section of another string. More... | |
virtual int | Compare (string string1, int offset1, string string2, int offset2, CompareOptions options) |
Compares the end section of a string with the end section of another string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | Compare (string string1, int offset1, string string2, int offset2) |
Compares the end section of a string with the end section of another string. More... | |
virtual int | Compare (string string1, int offset1, int length1, string string2, int offset2, int length2, CompareOptions options) |
Compares a section of one string with a section of another string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual bool | IsPrefix (string source, string prefix, CompareOptions options) |
Determines whether the specified source string starts with the specified prefix using the specified T:System.Globalization.CompareOptions value. More... | |
virtual bool | IsPrefix (string source, string prefix) |
Determines whether the specified source string starts with the specified prefix. More... | |
virtual bool | IsSuffix (string source, string suffix, CompareOptions options) |
Determines whether the specified source string ends with the specified suffix using the specified T:System.Globalization.CompareOptions value. More... | |
virtual bool | IsSuffix (string source, string suffix) |
Determines whether the specified source string ends with the specified suffix. More... | |
virtual int | IndexOf (string source, char value) |
Searches for the specified character and returns the zero-based index of the first occurrence within the entire source string. More... | |
virtual int | IndexOf (string source, string value) |
Searches for the specified substring and returns the zero-based index of the first occurrence within the entire source string. More... | |
virtual int | IndexOf (string source, char value, CompareOptions options) |
Searches for the specified character and returns the zero-based index of the first occurrence within the entire source string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | IndexOf (string source, string value, CompareOptions options) |
Searches for the specified substring and returns the zero-based index of the first occurrence within the entire source string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | IndexOf (string source, char value, int startIndex) |
Searches for the specified character and returns the zero-based index of the first occurrence within the section of the source string that extends from the specified index to the end of the string. More... | |
virtual int | IndexOf (string source, string value, int startIndex) |
Searches for the specified substring and returns the zero-based index of the first occurrence within the section of the source string that extends from the specified index to the end of the string. More... | |
virtual int | IndexOf (string source, char value, int startIndex, CompareOptions options) |
Searches for the specified character and returns the zero-based index of the first occurrence within the section of the source string that extends from the specified index to the end of the string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | IndexOf (string source, string value, int startIndex, CompareOptions options) |
Searches for the specified substring and returns the zero-based index of the first occurrence within the section of the source string that extends from the specified index to the end of the string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | IndexOf (string source, char value, int startIndex, int count) |
Searches for the specified character and returns the zero-based index of the first occurrence within the section of the source string that starts at the specified index and contains the specified number of elements. More... | |
virtual int | IndexOf (string source, string value, int startIndex, int count) |
Searches for the specified substring and returns the zero-based index of the first occurrence within the section of the source string that starts at the specified index and contains the specified number of elements. More... | |
virtual int | IndexOf (string source, char value, int startIndex, int count, CompareOptions options) |
Searches for the specified character and returns the zero-based index of the first occurrence within the section of the source string that starts at the specified index and contains the specified number of elements using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | IndexOf (string source, string value, int startIndex, int count, CompareOptions options) |
Searches for the specified substring and returns the zero-based index of the first occurrence within the section of the source string that starts at the specified index and contains the specified number of elements using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | LastIndexOf (string source, char value) |
Searches for the specified character and returns the zero-based index of the last occurrence within the entire source string. More... | |
virtual int | LastIndexOf (string source, string value) |
Searches for the specified substring and returns the zero-based index of the last occurrence within the entire source string. More... | |
virtual int | LastIndexOf (string source, char value, CompareOptions options) |
Searches for the specified character and returns the zero-based index of the last occurrence within the entire source string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | LastIndexOf (string source, string value, CompareOptions options) |
Searches for the specified substring and returns the zero-based index of the last occurrence within the entire source string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | LastIndexOf (string source, char value, int startIndex) |
Searches for the specified character and returns the zero-based index of the last occurrence within the section of the source string that extends from the beginning of the string to the specified index. More... | |
virtual int | LastIndexOf (string source, string value, int startIndex) |
Searches for the specified substring and returns the zero-based index of the last occurrence within the section of the source string that extends from the beginning of the string to the specified index. More... | |
virtual int | LastIndexOf (string source, char value, int startIndex, CompareOptions options) |
Searches for the specified character and returns the zero-based index of the last occurrence within the section of the source string that extends from the beginning of the string to the specified index using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | LastIndexOf (string source, string value, int startIndex, CompareOptions options) |
Searches for the specified substring and returns the zero-based index of the last occurrence within the section of the source string that extends from the beginning of the string to the specified index using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | LastIndexOf (string source, char value, int startIndex, int count) |
Searches for the specified character and returns the zero-based index of the last occurrence within the section of the source string that contains the specified number of elements and ends at the specified index. More... | |
virtual int | LastIndexOf (string source, string value, int startIndex, int count) |
Searches for the specified substring and returns the zero-based index of the last occurrence within the section of the source string that contains the specified number of elements and ends at the specified index. More... | |
virtual int | LastIndexOf (string source, char value, int startIndex, int count, CompareOptions options) |
Searches for the specified character and returns the zero-based index of the last occurrence within the section of the source string that contains the specified number of elements and ends at the specified index using the specified T:System.Globalization.CompareOptions value. More... | |
virtual int | LastIndexOf (string source, string value, int startIndex, int count, CompareOptions options) |
Searches for the specified substring and returns the zero-based index of the last occurrence within the section of the source string that contains the specified number of elements and ends at the specified index using the specified T:System.Globalization.CompareOptions value. More... | |
virtual SortKey | GetSortKey (string source, CompareOptions options) |
Gets a T:System.Globalization.SortKey object for the specified string using the specified T:System.Globalization.CompareOptions value. More... | |
virtual SortKey | GetSortKey (string source) |
Gets the sort key for the specified string. More... | |
override bool | Equals (object value) |
Determines whether the specified object is equal to the current T:System.Globalization.CompareInfo object. More... | |
override int | GetHashCode () |
Serves as a hash function for the current T:System.Globalization.CompareInfo for hashing algorithms and data structures, such as a hash table. More... | |
virtual int | GetHashCode (string source, CompareOptions options) |
Gets the hash code for a string based on specified comparison options. More... | |
override string | ToString () |
Returns a string that represents the current T:System.Globalization.CompareInfo object. More... | |
Static Public Member Functions | |
static CompareInfo | GetCompareInfo (int culture, Assembly assembly) |
Initializes a new T:System.Globalization.CompareInfo object that is associated with the specified culture and that uses string comparison methods in the specified T:System.Reflection.Assembly. More... | |
static CompareInfo | GetCompareInfo (string name, Assembly assembly) |
Initializes a new T:System.Globalization.CompareInfo object that is associated with the specified culture and that uses string comparison methods in the specified T:System.Reflection.Assembly. More... | |
static CompareInfo | GetCompareInfo (int culture) |
Initializes a new T:System.Globalization.CompareInfo object that is associated with the culture with the specified identifier. More... | |
static CompareInfo | GetCompareInfo (string name) |
Initializes a new T:System.Globalization.CompareInfo object that is associated with the culture with the specified name. More... | |
static bool | IsSortable (char ch) |
Indicates whether a specified Unicode character is sortable. More... | |
static bool | IsSortable (string text) |
Indicates whether a specified Unicode string is sortable. More... | |
Public Attributes | |
int | LCID => CultureInfo.GetCultureInfo(Name).LCID |
Gets the properly formed culture identifier for the current T:System.Globalization.CompareInfo. More... | |
Properties | |
virtual string | Name [get] |
Gets the name of the culture used for sorting operations by this T:System.Globalization.CompareInfo object. More... | |
SortVersion? | Version [get] |
Gets information about the version of Unicode used for comparing and sorting strings. More... | |
Implements a set of methods for culture-sensitive string comparisons.
Definition at line 13 of file CompareInfo.cs.
|
virtual |
Compares two strings.
string1 | The first string to compare. |
string2 | The second string to compare. |
Definition at line 313 of file CompareInfo.cs.
|
virtual |
Compares two strings using the specified T:System.Globalization.CompareOptions value.
string1 | The first string to compare. |
string2 | The second string to compare. |
options | A value that defines how string1 and string2 should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, F:System.Globalization.CompareOptions.IgnoreKanaType, and F:System.Globalization.CompareOptions.StringSort. |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 329 of file CompareInfo.cs.
|
virtual |
Compares a section of one string with a section of another string.
string1 | The first string to compare. |
offset1 | The zero-based index of the character in string1 at which to start comparing. |
length1 | The number of consecutive characters in string1 to compare. |
string2 | The second string to compare. |
offset2 | The zero-based index of the character in string2 at which to start comparing. |
length2 | The number of consecutive characters in string2 to compare. |
T:System.ArgumentOutOfRangeException | offset1 or length1 or offset2 or length2 is less than zero.-or- offset1 is greater than or equal to the number of characters in string1 .-or- offset2 is greater than or equal to the number of characters in string2 .-or- length1 is greater than the number of characters from offset1 to the end of string1 .-or- length2 is greater than the number of characters from offset2 to the end of string2 . |
Definition at line 377 of file CompareInfo.cs.
|
virtual |
Compares the end section of a string with the end section of another string using the specified T:System.Globalization.CompareOptions value.
string1 | The first string to compare. |
offset1 | The zero-based index of the character in string1 at which to start comparing. |
string2 | The second string to compare. |
offset2 | The zero-based index of the character in string2 at which to start comparing. |
options | A value that defines how string1 and string2 should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, F:System.Globalization.CompareOptions.IgnoreKanaType, and F:System.Globalization.CompareOptions.StringSort. |
T:System.ArgumentOutOfRangeException | offset1 or offset2 is less than zero.-or- offset1 is greater than or equal to the number of characters in string1 .-or- offset2 is greater than or equal to the number of characters in string2 . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 396 of file CompareInfo.cs.
|
virtual |
Compares the end section of a string with the end section of another string.
string1 | The first string to compare. |
offset1 | The zero-based index of the character in string1 at which to start comparing. |
string2 | The second string to compare. |
offset2 | The zero-based index of the character in string2 at which to start comparing. |
T:System.ArgumentOutOfRangeException | offset1 or offset2 is less than zero.-or- offset1 is greater than or equal to the number of characters in string1 .-or- offset2 is greater than or equal to the number of characters in string2 . |
Definition at line 412 of file CompareInfo.cs.
|
virtual |
Compares a section of one string with a section of another string using the specified T:System.Globalization.CompareOptions value.
string1 | The first string to compare. |
offset1 | The zero-based index of the character in string1 at which to start comparing. |
length1 | The number of consecutive characters in string1 to compare. |
string2 | The second string to compare. |
offset2 | The zero-based index of the character in string2 at which to start comparing. |
length2 | The number of consecutive characters in string2 to compare. |
options | A value that defines how string1 and string2 should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, F:System.Globalization.CompareOptions.IgnoreKanaType, and F:System.Globalization.CompareOptions.StringSort. |
T:System.ArgumentOutOfRangeException | offset1 or length1 or offset2 or length2 is less than zero.-or- offset1 is greater than or equal to the number of characters in string1 .-or- offset2 is greater than or equal to the number of characters in string2 .-or- length1 is greater than the number of characters from offset1 to the end of string1 .-or- length2 is greater than the number of characters from offset2 to the end of string2 . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 436 of file CompareInfo.cs.
override bool System.Globalization.CompareInfo.Equals | ( | object | value | ) |
Determines whether the specified object is equal to the current T:System.Globalization.CompareInfo object.
value | The object to compare with the current T:System.Globalization.CompareInfo. |
true
if the specified object is equal to the current T:System.Globalization.CompareInfo; otherwise, false
.Definition at line 1263 of file CompareInfo.cs.
|
static |
Initializes a new T:System.Globalization.CompareInfo object that is associated with the specified culture and that uses string comparison methods in the specified T:System.Reflection.Assembly.
culture | An integer representing the culture identifier. |
assembly | An T:System.Reflection.Assembly that contains the string comparison methods to use. |
T:System.ArgumentNullException | assembly is null . |
T:System.ArgumentException | assembly is of an invalid type. |
Definition at line 133 of file CompareInfo.cs.
|
static |
Initializes a new T:System.Globalization.CompareInfo object that is associated with the specified culture and that uses string comparison methods in the specified T:System.Reflection.Assembly.
name | A string representing the culture name. |
assembly | An T:System.Reflection.Assembly that contains the string comparison methods to use. |
T:System.ArgumentNullException | name is null .-or- assembly is null . |
T:System.ArgumentException | name is an invalid culture name.-or- assembly is of an invalid type. |
Definition at line 156 of file CompareInfo.cs.
|
static |
Initializes a new T:System.Globalization.CompareInfo object that is associated with the culture with the specified identifier.
culture | An integer representing the culture identifier. |
Definition at line 172 of file CompareInfo.cs.
|
static |
Initializes a new T:System.Globalization.CompareInfo object that is associated with the culture with the specified name.
name | A string representing the culture name. |
T:System.ArgumentNullException | name is null . |
T:System.ArgumentException | name is an invalid culture name. |
Definition at line 189 of file CompareInfo.cs.
override int System.Globalization.CompareInfo.GetHashCode | ( | ) |
Serves as a hash function for the current T:System.Globalization.CompareInfo for hashing algorithms and data structures, such as a hash table.
Definition at line 1276 of file CompareInfo.cs.
|
virtual |
Gets the hash code for a string based on specified comparison options.
source | The string whose hash code is to be returned. |
options | A value that determines how strings are compared. |
T:System.ArgumentNullException | source is null . |
Definition at line 1288 of file CompareInfo.cs.
|
virtual |
Gets a T:System.Globalization.SortKey object for the specified string using the specified T:System.Globalization.CompareOptions value.
source | The string for which a T:System.Globalization.SortKey object is obtained. |
options | A bitwise combination of one or more of the following enumeration values that define how the sort key is calculated: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, F:System.Globalization.CompareOptions.IgnoreKanaType, and F:System.Globalization.CompareOptions.StringSort. |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 1210 of file CompareInfo.cs.
|
virtual |
Gets the sort key for the specified string.
source | The string for which a T:System.Globalization.SortKey object is obtained. |
Definition at line 1218 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the first occurrence within the entire source string.
source | The string to search. |
value | The character to locate within source . |
T:System.ArgumentNullException | source is null . |
Definition at line 623 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the first occurrence within the entire source string.
source | The string to search. |
value | The string to locate within source . |
T:System.ArgumentNullException | source is null .-or- value is null . |
Definition at line 640 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the first occurrence within the entire source string using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The character to locate within source . |
options | A value that defines how the strings should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 659 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the first occurrence within the entire source string using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The string to locate within source . |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 679 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the first occurrence within the section of the source string that extends from the specified index to the end of the string.
source | The string to search. |
value | The character to locate within source . |
startIndex | The zero-based starting index of the search. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source . |
Definition at line 697 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the first occurrence within the section of the source string that extends from the specified index to the end of the string.
source | The string to search. |
value | The string to locate within source . |
startIndex | The zero-based starting index of the search. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source . |
Definition at line 716 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the first occurrence within the section of the source string that extends from the specified index to the end of the string using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The character to locate within source . |
startIndex | The zero-based starting index of the search. |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 738 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the first occurrence within the section of the source string that extends from the specified index to the end of the string using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The string to locate within source . |
startIndex | The zero-based starting index of the search. |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 761 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the first occurrence within the section of the source string that starts at the specified index and contains the specified number of elements.
source | The string to search. |
value | The character to locate within source . |
startIndex | The zero-based starting index of the search. |
count | The number of elements in the section to search. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source .-or- count is less than zero.-or- startIndex and count do not specify a valid section in source . |
Definition at line 783 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the first occurrence within the section of the source string that starts at the specified index and contains the specified number of elements.
source | The string to search. |
value | The string to locate within source . |
startIndex | The zero-based starting index of the search. |
count | The number of elements in the section to search. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source .-or- count is less than zero.-or- startIndex and count do not specify a valid section in source . |
Definition at line 802 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the first occurrence within the section of the source string that starts at the specified index and contains the specified number of elements using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The character to locate within source . |
startIndex | The zero-based starting index of the search. |
count | The number of elements in the section to search. |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source .-or- count is less than zero.-or- startIndex and count do not specify a valid section in source . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 824 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the first occurrence within the section of the source string that starts at the specified index and contains the specified number of elements using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The string to locate within source . |
startIndex | The zero-based starting index of the search. |
count | The number of elements in the section to search. |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source .-or- count is less than zero.-or- startIndex and count do not specify a valid section in source . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 867 of file CompareInfo.cs.
|
virtual |
Determines whether the specified source string starts with the specified prefix using the specified T:System.Globalization.CompareOptions value.
source | The string to search in. |
prefix | The string to compare with the beginning of source . |
options | A value that defines how source and prefix should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
true
if the length of prefix is less than or equal to the length of source and source starts with prefix ; otherwise, false
.T:System.ArgumentNullException | source is null .-or- prefix is null . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 525 of file CompareInfo.cs.
|
virtual |
Determines whether the specified source string starts with the specified prefix.
source | The string to search in. |
prefix | The string to compare with the beginning of source . |
true
if the length of prefix is less than or equal to the length of source and source starts with prefix ; otherwise, false
.T:System.ArgumentNullException | source is null .-or- prefix is null . |
Definition at line 559 of file CompareInfo.cs.
|
static |
Indicates whether a specified Unicode character is sortable.
ch | A Unicode character. |
true
if the ch parameter is sortable; otherwise, false
.Definition at line 203 of file CompareInfo.cs.
|
static |
Indicates whether a specified Unicode string is sortable.
text | A string of zero or more Unicode characters. |
true
if the str parameter is not an empty string ("") and all the Unicode characters in str are sortable; otherwise, false
.T:System.ArgumentNullException | str is null . |
Definition at line 216 of file CompareInfo.cs.
|
virtual |
Determines whether the specified source string ends with the specified suffix using the specified T:System.Globalization.CompareOptions value.
source | The string to search in. |
suffix | The string to compare with the end of source . |
options | A value that defines how source and suffix should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal used by itself, or the bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
true
if the length of suffix is less than or equal to the length of source and source ends with suffix ; otherwise, false
.T:System.ArgumentNullException | source is null .-or- suffix is null . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 577 of file CompareInfo.cs.
|
virtual |
Determines whether the specified source string ends with the specified suffix.
source | The string to search in. |
suffix | The string to compare with the end of source . |
true
if the length of suffix is less than or equal to the length of source and source ends with suffix ; otherwise, false
.T:System.ArgumentNullException | source is null .-or- suffix is null . |
Definition at line 611 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the last occurrence within the entire source string.
source | The string to search. |
value | The character to locate within source . |
T:System.ArgumentNullException | source is null . |
Definition at line 915 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the last occurrence within the entire source string.
source | The string to search. |
value | The string to locate within source . |
T:System.ArgumentNullException | source is null .-or- value is null . |
Definition at line 932 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the last occurrence within the entire source string using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The character to locate within source . |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 951 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the last occurrence within the entire source string using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The string to locate within source . |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 971 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the last occurrence within the section of the source string that extends from the beginning of the string to the specified index.
source | The string to search. |
value | The character to locate within source . |
startIndex | The zero-based starting index of the backward search. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source . |
Definition at line 989 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the last occurrence within the section of the source string that extends from the beginning of the string to the specified index.
source | The string to search. |
value | The string to locate within source . |
startIndex | The zero-based starting index of the backward search. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source . |
Definition at line 1004 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the last occurrence within the section of the source string that extends from the beginning of the string to the specified index using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The character to locate within source . |
startIndex | The zero-based starting index of the backward search. |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 1022 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the last occurrence within the section of the source string that extends from the beginning of the string to the specified index using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The string to locate within source . |
startIndex | The zero-based starting index of the backward search. |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 1041 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the last occurrence within the section of the source string that contains the specified number of elements and ends at the specified index.
source | The string to search. |
value | The character to locate within source . |
startIndex | The zero-based starting index of the backward search. |
count | The number of elements in the section to search. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source .-or- count is less than zero.-or- startIndex and count do not specify a valid section in source . |
Definition at line 1059 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the last occurrence within the section of the source string that contains the specified number of elements and ends at the specified index.
source | The string to search. |
value | The string to locate within source . |
startIndex | The zero-based starting index of the backward search. |
count | The number of elements in the section to search. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source .-or- count is less than zero.-or- startIndex and count do not specify a valid section in source . |
Definition at line 1078 of file CompareInfo.cs.
|
virtual |
Searches for the specified character and returns the zero-based index of the last occurrence within the section of the source string that contains the specified number of elements and ends at the specified index using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The character to locate within source . |
startIndex | The zero-based starting index of the backward search. |
count | The number of elements in the section to search. |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source .-or- count is less than zero.-or- startIndex and count do not specify a valid section in source . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 1100 of file CompareInfo.cs.
|
virtual |
Searches for the specified substring and returns the zero-based index of the last occurrence within the section of the source string that contains the specified number of elements and ends at the specified index using the specified T:System.Globalization.CompareOptions value.
source | The string to search. |
value | The string to locate within source . |
startIndex | The zero-based starting index of the backward search. |
count | The number of elements in the section to search. |
options | A value that defines how source and value should be compared. options is either the enumeration value F:System.Globalization.CompareOptions.Ordinal, or a bitwise combination of one or more of the following values: F:System.Globalization.CompareOptions.IgnoreCase, F:System.Globalization.CompareOptions.IgnoreSymbols, F:System.Globalization.CompareOptions.IgnoreNonSpace, F:System.Globalization.CompareOptions.IgnoreWidth, and F:System.Globalization.CompareOptions.IgnoreKanaType. |
T:System.ArgumentNullException | source is null .-or- value is null . |
T:System.ArgumentOutOfRangeException | startIndex is outside the range of valid indexes for source .-or- count is less than zero.-or- startIndex and count do not specify a valid section in source . |
T:System.ArgumentException | options contains an invalid T:System.Globalization.CompareOptions value. |
Definition at line 1155 of file CompareInfo.cs.
override string System.Globalization.CompareInfo.ToString | ( | ) |
Returns a string that represents the current T:System.Globalization.CompareInfo object.
Definition at line 1331 of file CompareInfo.cs.
int System.Globalization.CompareInfo.LCID => CultureInfo.GetCultureInfo(Name).LCID |
Gets the properly formed culture identifier for the current T:System.Globalization.CompareInfo.
Definition at line 86 of file CompareInfo.cs.
|
get |
Gets the name of the culture used for sorting operations by this T:System.Globalization.CompareInfo object.
Definition at line 72 of file CompareInfo.cs.
|
get |
Gets information about the version of Unicode used for comparing and sorting strings.
Definition at line 102 of file CompareInfo.cs.