public static ContainerIdentification Parse(RawContainerIdentification rawContainerIdentification) { Utilities.Parse(rawContainerIdentification.Value, out var ownerCodeValue, out var equipmentCategoryString, out var serialNumberValue); var containerIdentification = ContainerIdentification.NewFrom(ownerCodeValue, equipmentCategoryString, serialNumberValue); return(containerIdentification); }
public static DescribedResult <bool> TryValidate(UnvalidatedRawContainerIdentification unvalidatedRawContainerIdentification, out RawContainerIdentification rawContainerIdentification) { var isValid = Utilities.IsValid(unvalidatedRawContainerIdentification); if (isValid.Value) { rawContainerIdentification = new RawContainerIdentification(unvalidatedRawContainerIdentification.Value); } else { rawContainerIdentification = RawContainerIdentification.Invalid; } return(isValid); }
public static DescribedResult <bool> IsValid(RawContainerIdentification rawContainerIdentification) { var output = Utilities.IsValidRawContainerIdentification(rawContainerIdentification.Value); return(output); }