| | | 1 | | // ----------------------------------------------------------------------- |
| | | 2 | | // <copyright file="Casing.cs" company="Stéphane ANDRE"> |
| | | 3 | | // Copyright (c) Stéphane ANDRE. All rights reserved. |
| | | 4 | | // </copyright> |
| | | 5 | | // ----------------------------------------------------------------------- |
| | | 6 | | |
| | | 7 | | namespace MyNet.Text.TextCasing; |
| | | 8 | | |
| | | 9 | | /// <summary> |
| | | 10 | | /// Provides common text casing transformations. |
| | | 11 | | /// </summary> |
| | | 12 | | public static class Casing |
| | | 13 | | { |
| | | 14 | | /// <summary> |
| | | 15 | | /// Gets transforms a string to upper case. |
| | | 16 | | /// </summary> |
| | 6 | 17 | | public static ITextCasingTransform UpperCase { get; } = new UpperCasingTransform(); |
| | | 18 | | |
| | | 19 | | /// <summary> |
| | | 20 | | /// Gets transforms a string to lower case. |
| | | 21 | | /// </summary> |
| | 6 | 22 | | public static ITextCasingTransform LowerCase { get; } = new LowerCasingTransform(); |
| | | 23 | | |
| | | 24 | | /// <summary> |
| | | 25 | | /// Gets transforms a string to title case. |
| | | 26 | | /// </summary> |
| | 6 | 27 | | public static ITextCasingTransform TitleCase { get; } = new TitleCasingTransform(); |
| | | 28 | | |
| | | 29 | | /// <summary> |
| | | 30 | | /// Gets transforms a string to sentence case. |
| | | 31 | | /// </summary> |
| | 6 | 32 | | public static ITextCasingTransform SentenceCase { get; } = new SentenceCasingTransform(); |
| | | 33 | | |
| | | 34 | | /// <summary> |
| | | 35 | | /// Gets transforms a string to PascalCase. |
| | | 36 | | /// </summary> |
| | 6 | 37 | | public static ITextCasingTransform PascalCase { get; } = new PascalCasingTransform(); |
| | | 38 | | |
| | | 39 | | /// <summary> |
| | | 40 | | /// Gets transforms a string to camelCase. |
| | | 41 | | /// </summary> |
| | 6 | 42 | | public static ITextCasingTransform CamelCase { get; } = new CamelCasingTransform(); |
| | | 43 | | |
| | | 44 | | /// <summary> |
| | | 45 | | /// Gets transforms a string to snake_case. |
| | | 46 | | /// </summary> |
| | 6 | 47 | | public static ITextCasingTransform SnakeCase { get; } = new SnakeCasingTransform(); |
| | | 48 | | |
| | | 49 | | /// <summary> |
| | | 50 | | /// Gets transforms a string to kebab-case. |
| | | 51 | | /// </summary> |
| | 6 | 52 | | public static ITextCasingTransform KebabCase { get; } = new KebabCasingTransform(); |
| | | 53 | | } |
| | | 54 | | |