1234567891011121314151617181920212223242526272829303132333435363738 |
- using System.Linq;
- namespace FlutterCodeGenerator
- {
- public class LetterConverterHelper
- {
-
-
-
-
-
- public static string FirstCharToLower(string input)
- {
- if (string.IsNullOrEmpty(input))
- return input;
- var str = input.First().ToString().ToLower() + input.Substring(1);
- return str;
- }
-
-
-
-
-
- public static string FirstCharToUpper(string input)
- {
- if (string.IsNullOrEmpty(input))
- return input;
- var firstChar = input[0];
- if (firstChar >= 'a' && firstChar <= 'z')
- {
- return input;
- }
- var str = input.First().ToString().ToUpper() + input.Substring(1);
- return str;
- }
- }
- }
|