/// <summary> /// Validates this CDA Context /// </summary> /// <param name="path">The path to this object as a string</param> /// <param name="messages">the validation messages, these may be added to within this method</param> void ICDAContextEPrescription.Validate(string path, List <ValidationMessage> messages) { var vb = new ValidationBuilder(path, messages); if (LegalAuthenticator != null) { LegalAuthenticator.ValidateATS(vb.Path + "LegalAuthenticator", vb.Messages); } if (InformationRecipients != null) { for (var x = 0; x < InformationRecipients.Count; x++) { InformationRecipients[x].Validate(vb.Path + string.Format("InformationRecipients[{0}]", x), vb.Messages); } } if (vb.ArgumentRequiredCheck("Custodian", Custodian)) { if (Custodian != null) { Custodian.ValidateATS(vb.Path + "Custodian", vb.Messages); } } }