Class CStyleStringFormatting
Methods for C-Style string formats
Inheritance
System.Object
CStyleStringFormatting
Namespace: MESL.SqlRace.Domain.Infrastructure.Formatting
Assembly: MESL.SqlRace.Domain.dll
Syntax
public static class CStyleStringFormatting : Object
Methods
CStyleFormat(String, Object[])
Converts C-style format strings.
Declaration
public static string CStyleFormat(string format, params object[] parameters)
Parameters
Type | Name | Description |
---|---|---|
System.String | format | The format. |
System.Object[] | parameters | The parameters. |
Returns
Type | Description |
---|---|
System.String | Formatted string |
FormatIPAddress(Double)
Convert an IP value to a string.
Declaration
public static string FormatIPAddress(double inputValue)
Parameters
Type | Name | Description |
---|---|---|
System.Double | inputValue | The input value. |
Returns
Type | Description |
---|---|
System.String | The IP address as a string. |
FormatIPAddress(Int64)
Convert an IP value to a string.
Declaration
public static string FormatIPAddress(long inputValue)
Parameters
Type | Name | Description |
---|---|---|
System.Int64 | inputValue | The input value. |
Returns
Type | Description |
---|---|
System.String | The IP address as a string. |
IsCStyleFormatstring(String)
Determines whether the specified string is a C style format string.
Declaration
public static bool IsCStyleFormatstring(string formatString)
Parameters
Type | Name | Description |
---|---|---|
System.String | formatString | The format string. |
Returns
Type | Description |
---|---|
System.Boolean | Returns |
IsIPAddressFormatString(String)
Determines whether the specified string is for an IPAddress (%qIP)
Declaration
public static bool IsIPAddressFormatString(string formatString)
Parameters
Type | Name | Description |
---|---|---|
System.String | formatString | The Format string |
Returns
Type | Description |
---|---|
System.Boolean | Returns |