PeterO.CulturedText
PeterO.CulturedText
public static class CulturedText
Contains string processing operations that should be formatted according to the current locale's formatting rules.
This class, along with the InvariantText class, supports the correct use f string functions in the framework. InvariantText is intended for use in ocale-independent string processing, such as data and file system rocessing, while CulturedText is intended for text display. Use ulturedText for formatting the messages of exceptions and within the onsole.Write method.
Compare
public static int Compare( string value1, string value2);
Compares a text string with a string.
Parameters:
value1: The parameter value1 is a text string.
value2: The parameter value2 is a text string.
Return Value:
A 32-bit signed integer.
CompareIgnoreCase
public static int CompareIgnoreCase( string value1, string value2);
Not documented yet.
Parameters:
value1: The parameter value1 is a text string.
value2: The parameter value2 is a text string.
Return Value:
A 32-bit signed integer.
EndsWith
public static bool EndsWith( string value1, string value2);
Not documented yet.
Parameters:
value1: The parameter value1 is a text string.
value2: The parameter value2 is a text string.
Return Value:
Either true
or false
.
Exceptions:
- System.ArgumentNullException: The parameter value1 is null.
Format
public static string Format( string formattedText, params object[] options);
Not documented yet.
Parameters:
formattedText: The parameter formattedText is a text string.
options: The parameter options is a params object.
Return Value:
A text string.
ParseInt32
public static int ParseInt32( string value);
Not documented yet.
Parameters:
- value: The parameter value is a text string.
Return Value:
A 32-bit signed integer.
ParseInt32Hex
public static int ParseInt32Hex( string value);
Not documented yet.
Parameters:
- value: The parameter value is a text string.
Return Value:
A 32-bit signed integer.
StartsWith
public static bool StartsWith( string value1, string value2);
Not documented yet.
Parameters:
value1: The parameter value1 is a text string.
value2: The parameter value2 is a text string.
Return Value:
Either true
or false
.
Exceptions:
- System.ArgumentNullException: The parameter value1 is null.
ToString
public static string ToString( byte value);
Converts this object to a text string.
Parameters:
- value: The parameter value is a byte (from 0 to 255).
Return Value:
A text string.
ToString
public static string ToString( double value);
Converts this object to a text string.
Parameters:
- value: The parameter value is a 64-bit floating-point number.
Return Value:
A text string.
ToString
public static string ToString( float value);
Converts this object to a text string.
Parameters:
- value: The parameter value is a 32-bit floating-point number.
Return Value:
A text string.
ToString
public static string ToString( int value);
Converts this object to a text string.
Parameters:
- value: The parameter value is a 32-bit signed integer.
Return Value:
A text string.
ToString
public static string ToString( long value);
Converts this object to a text string.
Parameters:
- value: The parameter value is a 64-bit signed integer.
Return Value:
A text string.
ToString
public static string ToString( object value);
Converts this object to a text string.
Parameters:
- value: The parameter value is an arbitrary object.
Return Value:
A text string.
ToString
public static string ToString( short value);
Converts this object to a text string.
Parameters:
- value: The parameter value is a 16-bit signed integer.
Return Value:
A text string.