Represents a composite format string, along with the arguments to be formatted.
More...
|
abstract object [] | GetArguments () |
| Returns an object array that contains one or more objects to format. More...
|
|
abstract object | GetArgument (int index) |
| Returns the argument at the specified index position. More...
|
|
abstract string | ToString (IFormatProvider formatProvider) |
| Returns the string that results from formatting the composite format string along with its arguments by using the formatting conventions of a specified culture. More...
|
|
override string | ToString () |
| Returns the string that results from formatting the composite format string along with its arguments by using the formatting conventions of the current culture. More...
|
|
|
static string | Invariant (FormattableString formattable) |
| Returns a result string in which arguments are formatted by using the conventions of the invariant culture. More...
|
|
Represents a composite format string, along with the arguments to be formatted.
Definition at line 7 of file FormattableString.cs.
◆ FormattableString()
System.FormattableString.FormattableString |
( |
| ) |
|
|
protected |
Instantiates a new instance of the T:System.FormattableString class.
Definition at line 79 of file FormattableString.cs.
◆ GetArgument()
abstract object System.FormattableString.GetArgument |
( |
int |
index | ) |
|
|
pure virtual |
Returns the argument at the specified index position.
- Parameters
-
index | The index of the argument. Its value can range from zero to one less than the value of P:System.FormattableString.ArgumentCount. |
- Returns
- The argument.
◆ GetArguments()
abstract object [] System.FormattableString.GetArguments |
( |
| ) |
|
|
pure virtual |
Returns an object array that contains one or more objects to format.
- Returns
- An object array that contains one or more objects to format.
◆ Invariant()
Returns a result string in which arguments are formatted by using the conventions of the invariant culture.
- Parameters
-
formattable | The object to convert to a result string. |
- Returns
- The string that results from formatting the current instance by using the conventions of the invariant culture.
- Exceptions
-
T:System.ArgumentNullException | formattable is null . |
Definition at line 60 of file FormattableString.cs.
◆ ToString() [1/2]
abstract string System.FormattableString.ToString |
( |
IFormatProvider |
formatProvider | ) |
|
|
pure virtual |
Returns the string that results from formatting the composite format string along with its arguments by using the formatting conventions of a specified culture.
- Parameters
-
formatProvider | An object that provides culture-specific formatting information. |
- Returns
- A result string formatted by using the conventions of formatProvider .
◆ ToString() [2/2]
override string System.FormattableString.ToString |
( |
| ) |
|
Returns the string that results from formatting the composite format string along with its arguments by using the formatting conventions of the current culture.
- Returns
- A result string formatted by using the conventions of the current culture.
Definition at line 72 of file FormattableString.cs.
◆ ArgumentCount
abstract int System.FormattableString.ArgumentCount |
|
get |
Gets the number of arguments to be formatted.
- Returns
- The number of arguments to be formatted.
Definition at line 22 of file FormattableString.cs.
◆ Format
abstract string System.FormattableString.Format |
|
get |
Returns the composite format string.
- Returns
- The composite format string.
Definition at line 13 of file FormattableString.cs.
The documentation for this class was generated from the following file: