Files
PIBD-23_Coursach_YouAreProg…/YouAreProgrammerShop/YAPContracts/Extentions/StringExtention.cs

22 lines
451 B
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace YAPContracts.Extentions
{
public static class StringExtention
{
public static bool IsEmpty(this string str)
{
return string.IsNullOrWhiteSpace(str);
}
public static bool IsGuid(this string str)
{
return Guid.TryParse(str, out _);
}
}
}