StringUtility class

Provides methods for manipulating strings.

public static class StringUtility

Public Members

name description
static CompareByCodePoint(…) Compares two specified String objects by comparing successive Unicode code points. This method differs from String) in that this method considers supplementary characters (which are encoded as two surrogate code units) to be greater than characters in the base multilingual plane (because they have higher Unicode code points). This method sorts strings in code point order, which is the same as a byte-wise comparison of UTF-8 or UTF-32 encoded strings.
static Compress(…) Compresses a string.
static CreateComparer(…) Creates a StringComparer ignoring or honoring the strings’ case, and using culture-specific information to influence the comparison.
static CreateCompressingTextWriter(…) Creates a TextWriter that writes compressed text to a stream that matches the format used by Compress.
static CreateDecompressingTextReader(…) Creates a TextReader that reads compressed text from a stream that matches the format used by Compress.
static Decompress(…) Decompresses a compressed string.
static EndsWithOrdinal(…) Calls string.EndsWith with StringComparison.Ordinal.
static FoldCase(…) Performs a full case folding as defined by Section 5.18 of the Unicode Standard 5.0.
static FormatInvariant(…) Formats the string using the invariant culture.
static GetPersistentHashCode(…) Gets a hash code for the specified string; this hash code is guaranteed not to change in future.
static IndexOfOrdinal(…) Calls string.IndexOf with StringComparison.Ordinal. (4 methods)
static Join(…) Joins the specified strings into one string. (4 methods)
static JoinFormat(…) Joins the specified strings using the specified separator format.
static LastIndexOfOrdinal(…) Calls string.LastIndexOf with StringComparison.Ordinal. (3 methods)
static ReplaceOrdinal(…) Calls string.Replace with StringComparison.Ordinal.
static Reverse(…) Reverses the specified string.
static SplitOnWhitespace(…) Splits the string on whitespace. (2 methods)
static StartsWithOrdinal(…) Calls string.StartsWith with StringComparison.Ordinal.

See Also