SamsonGame/Assets/Sources/Feel/MMTools/Tools/MMHelpers/MMString.cs

27 lines
663 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace MoreMountains.Tools
{
/// <summary>
/// String helpers
/// </summary>
public static class MMString
{
/// <summary>
/// Uppercases the first letter of the parameter string
/// </summary>
/// <param name="s"></param>
/// <returns></returns>
public static string UppercaseFirst(string s)
{
if (string.IsNullOrEmpty(s))
{
return string.Empty;
}
return char.ToUpper(s[0]) + s.Substring(1);
}
}
}