public static XElement MakeResponsiblePartyNode(ResponsibleParty c) { if (c == null || c.Name.IsBlank()) return null; return new XElement(gmd + "CI_ResponsibleParty", new XElement(gmd + "organisationName", new XElement(gco + "CharacterString", c.Name)), new XElement(gmd + "contactInfo", new XElement(gmd + "CI_Contact", new XElement(gmd + "address", new XElement(gmd + "CI_Address", new XElement(gmd + "electronicMailAddress", new XElement(gco + "CharacterString", c.Email)))))), new XElement(gmd + "role", new XElement(gmd + "CI_RoleCode", new XAttribute("codeList", "http://standards.iso.org/ittf/PubliclyAvailableStandards/ISO_19139_Schemas/resources/codelist/gmxCodelists.xml#CI_RoleCode"), new XAttribute("codeListValue", c.Role), c.Role))); // todo should ideally store the human-readable meaning as the element value, but for now using the codeListValue }
public Metadata() { Keywords = new List<MetadataKeyword>(); TemporalExtent = new TemporalExtent(); ResponsibleOrganisation = new ResponsibleParty(); MetadataPointOfContact = new ResponsibleParty(); BoundingBox = new BoundingBox(); }