CliStringUtil.ToCase Method
Definition
- Namespace
- DotMake.CommandLine
- Assembly
- DotMake.CommandLine.dll
Converts the string to a specific case.
public static string ToCase(string value, CliNameCasingConvention nameCasingConvention, CultureInfo culture = null, bool keepSpaces = false)
Parameters
valuestringA string instance.
nameCasingConventionCliNameCasingConventionThe name casing convention to convert to.
cultureCultureInfoAn object that supplies culture-specific casing rules. If
cultureis null, the invariant culture is used.keepSpacesboolWhether to keep a single space between words if there were any whitespace or punctuation in the original. This works only for LowerCase, UpperCase, TitleCase which allows spaces.