コード例 #1
0
        public HttpResponseMessage Create(IKey key, Resource resource)
        {
            var request     = (CommunicationRequest)resource;
            var xmlAsString = new FhirXmlSerializer().SerializeToString(request);
            var result      = new FhirXmlParser().Parse <CommunicationRequest>(xmlAsString);

            result.Id = Guid.NewGuid().ToString();
            return(HttpResponseHelper.ConvertResourceToHttpResponseMessage(result, HttpStatusCode.OK));
        }