Skip to main content

set_version_id

Function set_version_id 

Source
pub fn set_version_id(
    resource: &mut Resource,
) -> Result<(), OperationOutcomeError>
Expand description

Sets the version ID of a FHIR resource.

If the resource does not have a meta element, one is created. The versionId field is then populated with a newly generated ID.

ยงErrors

Returns an [OperationOutcomeError] if the resource does not contain a meta field or if the meta field is not of type Option<Box<Meta>>.