using System.Threading.Tasks; namespace JobsJobsJobs.Shared { /// /// The ID of a skill /// public record SkillId(ShortId Id) { /// /// Create a new skill ID /// /// A new skill ID public static async Task Create() => new SkillId(await ShortId.Create()); /// /// Attempt to create a skill ID from a string /// /// The prospective ID /// The skill ID /// If the string is not a valid skill ID public static SkillId Parse(string id) => new SkillId(ShortId.Parse(id)); public override string ToString() => Id.ToString(); } }