Class RomanNumerals
Provides a set of static methods related to Roman numerals.
public static class RomanNumerals
- Inheritance
-
RomanNumerals
- Inherited Members
Methods
CreateRomanIntensityProperty(TagTypeKey, string?, float, CultureInfo, ISeverityScheme, int)
Creates an instance of the ReportProperty class with a value represented with a Roman numeral character.
public static ReportProperty CreateRomanIntensityProperty(TagTypeKey type, string? key, float value, CultureInfo culture, ISeverityScheme severityScheme, int accuracyOrder)
Parameters
typeTagTypeKey- The type.
keystring- The name.
valuefloat- The value.
cultureCultureInfo- The culture.
severitySchemeISeverityScheme- The severity scheme.
accuracyOrderint- The accuracy of the value (AccuracyOrder).
Returns
- ReportProperty
- An instance of the ReportProperty class.
IntegerToRoman(int)
Converts an integer to a multi-character Roman numeral.
public static string IntegerToRoman(int number)
Parameters
numberint- The integer.
Returns
- string
- The multi-character Roman numeral correspoding to
number.
RomanToInteger(string)
Converts a multi-character Roman numeral to an integer.
public static int RomanToInteger(string roman)
Parameters
romanstring- The multi-character Roman numeral.
Returns
- int
- The integer corresponding to
roman.
ToRomanNumeralChar(int, CultureInfo)
Converts an integer to the corresponding Roman numeral character.
public static string ToRomanNumeralChar(int num, CultureInfo culture)
Parameters
numint- The number.
cultureCultureInfo- The culture.
Returns
- string
- The uppercase Roman numeral character corresponding to
num, or a generic string representation ofnumif it is not between 1 and 12 (both inclusive).