A class that can format Strings with nummeric or named placeholders/identifiers.
More...
|
| | StringFormatter (IFormatProvider formatProvider=null) |
| | Creates a new instance with a format provider.
|
| |
| string | Format (string format, params object[] values) |
| | Formats a String with numeric placeholders.
|
| |
| string | Format (string format, Map< String, Object > values) |
| | Formats a String with named placeholders.
|
| |
| string | Format (string format, object values) |
| | Formats a String with named placeholders.
|
| |
A class that can format Strings with nummeric or named placeholders/identifiers.
- Version
- 0.0.1
◆ StringFormatter()
| Joutsen.StringFormatter.StringFormatter |
( |
IFormatProvider |
formatProvider = null | ) |
|
Creates a new instance with a format provider.
- Parameters
-
| formatProvider | the format provider to use to format values into strings. Uses the InvariantCulture if null. |
- Since
- Unreleased
◆ Format() [1/3]
| string Joutsen.StringFormatter.Format |
( |
string |
format, |
|
|
Map< String, Object > |
values |
|
) |
| |
Formats a String with named placeholders.
- Parameters
-
| format | The format String containing named placeholders |
| values | Pairs of name and value where each name is a placeholder that will be replaced with the corresponding value returns The formatted String |
◆ Format() [2/3]
| string Joutsen.StringFormatter.Format |
( |
string |
format, |
|
|
object |
values |
|
) |
| |
Formats a String with named placeholders.
- Parameters
-
| format | The format String containing named placeholders |
| values | An System.Object where each property name used as a placeholder in the format String will be replaced with the properties value |
- Returns
- The formatted String
◆ Format() [3/3]
| string Joutsen.StringFormatter.Format |
( |
string |
format, |
|
|
params object[] |
values |
|
) |
| |
Formats a String with numeric placeholders.
- Parameters
-
| format | The format String |
| values | The objects that are filled into the format string according to their index in the array |
- Returns
- The formatted String