public static MohawkCollege.EHR.gpmr.COR.TypeReference Parse(DatatypeRef dtr) { MohawkCollege.EHR.gpmr.COR.TypeReference retVal = new MohawkCollege.EHR.gpmr.COR.TypeReference(); retVal.Name = dtr.Name.Contains(".") ? dtr.Name.Substring(0, dtr.Name.IndexOf(".")) : dtr.Name; retVal.Flavor = dtr.Name.Contains(".") ? dtr.Name : null; // JF: Fixed the removal of the . if (dtr.SupplierBindingArgumentDatatype != null && dtr.SupplierBindingArgumentDatatype.Count > 0) { retVal.GenericSupplier = new List <MohawkCollege.EHR.gpmr.COR.TypeReference>(); foreach (DatatypeRef sba in dtr.SupplierBindingArgumentDatatype) { retVal.GenericSupplier.Add(TypeReferenceParser.Parse(sba)); } } return(retVal); }
/// <summary> /// Parse a type reference from a string /// </summary> /// <param name="p">The string to parse</param> /// <returns>The processed type parameter</returns> internal static MohawkCollege.EHR.gpmr.COR.TypeReference Parse(string p) { DatatypeRef r = DatatypeRef.Parse(p); return(Parse(r)); }