Class Formatter
Formatting utilities (for reports).
Inherited Members
Namespace: Lucene.Net.Benchmarks.ByTask.Utils
Assembly: Lucene.Net.Benchmark.dll
Syntax
public static class Formatter
Methods
Format(int, double, string)
Formatting utilities (for reports).
Declaration
public static string Format(int numFracDigits, double f, string col)
Parameters
Type | Name | Description |
---|---|---|
int | numFracDigits | |
double | f | |
string | col |
Returns
Type | Description |
---|---|
string |
Format(int, float, string)
Pad a number from left.
Declaration
public static string Format(int numFracDigits, float f, string col)
Parameters
Type | Name | Description |
---|---|---|
int | numFracDigits | Number of digits in fraction part - must be 0 or 1 or 2. |
float | f | Number to be formatted. |
string | col | Column name (used for deciding on length). |
Returns
Type | Description |
---|---|
string | Formatted string. |
Format(int, string)
Pad a number from left.
Declaration
public static string Format(int n, string col)
Parameters
Type | Name | Description |
---|---|---|
int | n | Number to be formatted. |
string | col | Column name (used for deciding on length). |
Returns
Type | Description |
---|---|
string | Formatted string. |
Format(string, string)
Pad a string from right.
Declaration
public static string Format(string s, string col)
Parameters
Type | Name | Description |
---|---|---|
string | s | String to be formatted. |
string | col | Column name (used for deciding on length). |
Returns
Type | Description |
---|---|
string | Formatted string. |
FormatPaddLeft(string, string)
Pad a string from left.
Declaration
public static string FormatPaddLeft(string s, string col)
Parameters
Type | Name | Description |
---|---|---|
string | s | String to be formatted. |
string | col | Column name (used for deciding on length). |
Returns
Type | Description |
---|---|
string | Formatted string. |
FormatPaddRight(int, double, string)
Formatting utilities (for reports).
Declaration
public static string FormatPaddRight(int numFracDigits, double f, string col)
Parameters
Type | Name | Description |
---|---|---|
int | numFracDigits | |
double | f | |
string | col |
Returns
Type | Description |
---|---|
string |
FormatPaddRight(int, float, string)
Pad a number from right.
Declaration
public static string FormatPaddRight(int numFracDigits, float f, string col)
Parameters
Type | Name | Description |
---|---|---|
int | numFracDigits | Number of digits in fraction part - must be 0 or 1 or 2. |
float | f | Number to be formatted. |
string | col | Column name (used for deciding on length). |
Returns
Type | Description |
---|---|
string | Formatted string. |