// Custom marshaller to add the resourceType property, as required by the specification
345240
func (resource *StructureDefinition) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "StructureDefinition"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to StructureDefinition), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
1263407
func (resource *DocumentManifest) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "DocumentManifest"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to DocumentManifest), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
676164
func (resource *Binary) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Binary"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Binary), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
463825
func (resource *Coverage) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Coverage"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Coverage), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
475171
func (resource *ImagingObjectSelection) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "ImagingObjectSelection"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to ImagingObjectSelection), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
910235
func (resource *CarePlan) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "CarePlan"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to CarePlan), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
187243
func (resource *ValueSet) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "ValueSet"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to ValueSet), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
545413
func (resource *ReferralRequest) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "ReferralRequest"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to ReferralRequest), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
991970
func (resource *Basic) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Basic"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Basic), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
1190034
func (resource *Condition) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Condition"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Condition), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
953651
func (resource *NutritionOrder) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "NutritionOrder"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to NutritionOrder), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
563957
func (r Resource) MarshalJSON() ([]byte, error) {
	var ccResource struct {
		FilePath    string   `json:"path,omitempty"`
		Mode        string   `json:"mode,omitempty"`
		Checksum    Checksum `json:"checksum"`
		SizeInBytes int64    `json:"size_in_bytes"`
	}

	ccResource.FilePath = r.FilePath
	ccResource.SizeInBytes = r.SizeInBytes
	ccResource.Checksum = r.Checksum
	ccResource.Mode = strconv.FormatUint(uint64(r.Mode), 8)
	return json.Marshal(ccResource)
}
241185
func (resource *MessageHeader) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "MessageHeader"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to MessageHeader), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
224868
func (r Resource) MarshalJSON() ([]byte, error) {
	var ccResource struct {
		Filename string `json:"fn,omitempty"`
		Mode     string `json:"mode,omitempty"`
		SHA1     string `json:"sha1"`
		Size     int64  `json:"size"`
	}

	ccResource.Filename = r.Filename
	ccResource.Size = r.Size
	ccResource.SHA1 = r.SHA1
	ccResource.Mode = strconv.FormatUint(uint64(r.Mode), 8)
	return json.Marshal(ccResource)
}
816966
func (resource *DeviceComponent) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "DeviceComponent"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to DeviceComponent), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
266742
func (b *BytesResource) MarshalJSON() ([]byte, error) {
	return json.Marshal(string(b.data))
}
1050672
func (resource *OperationDefinition) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "OperationDefinition"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to OperationDefinition), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}