public Resource Delete(ResourceKey key) { var deletedResponse = FHIRbase.Call("fhir.delete") .WithText(key.TypeName) .WithText(key.ResourceId) .Cast<string>(); return FHIRbaseHelper.JsonToFhirResource(deletedResponse); }
public Resource VRead(ResourceKey key) { var readedResponse = FHIRbase.Call("fhir.vread") .WithText(key.TypeName) .WithText(key.VersionId) .Cast<string>(); return FHIRbaseHelper.JsonToFhirResource(readedResponse); }
public Resource ReadLastVersion(ResourceKey key) { var lastVersion = History(key.TypeName, key.ResourceId) .With(x => x.Entry) .Select(x => x.Resource) .Where(x => x.HasVersionId) .OrderBy(x => x.Meta.LastUpdated) .LastOrDefault(); return lastVersion; }
public bool IsLatest(ResourceKey key) { var result = FHIRbase.Call("fhir.is_latest") .WithText(key.TypeName) .WithText(key.ResourceId) .WithText(key.VersionId) .Cast<bool>(); return result; }
public bool IsExists(ResourceKey key) { return IsExists(key.TypeName, key.ResourceId); }
public bool IsDeleted(ResourceKey key) { return FHIRbase.Call("fhir.is_deleted") .WithText(key.TypeName) .WithText(key.ResourceId) .Cast<bool>(); }