// Custom marshaller to add the resourceType property, as required by the specification
326725
func (resource *ImagingStudy) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "ImagingStudy"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to ImagingStudy), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
627498
func (resource *EpisodeOfCare) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "EpisodeOfCare"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to EpisodeOfCare), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
443410
func (resource *EnrollmentRequest) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "EnrollmentRequest"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to EnrollmentRequest), 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)
}
1140600
func (resource *AuditEvent) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "AuditEvent"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to AuditEvent), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
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)
}
108706
func (resource *Person) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Person"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Person), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
833484
func (resource *Patient) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Patient"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Patient), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
968981
func (resource *Slot) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Slot"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Slot), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
642383
func (r Resource) MarshalJSON() ([]byte, error) {
	return json.Marshal(struct {
		Type           string
		CreationPolicy *CreationPolicy        `json:",omitempty"`
		DeletionPolicy string                 `json:",omitempty"`
		DependsOn      []string               `json:",omitempty"`
		Metadata       map[string]interface{} `json:",omitempty"`
		UpdatePolicy   *UpdatePolicy          `json:",omitempty"`
		Condition      string                 `json:",omitempty"`
		Properties     ResourceProperties
	}{
		Type:           r.Properties.CfnResourceType(),
		CreationPolicy: r.CreationPolicy,
		DeletionPolicy: r.DeletionPolicy,
		DependsOn:      r.DependsOn,
		Metadata:       r.Metadata,
		UpdatePolicy:   r.UpdatePolicy,
		Condition:      r.Condition,
		Properties:     r.Properties,
	})
}
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)
}
691778
func (resource *Subscription) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Subscription"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Subscription), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
62786
func (resource *DeviceUseRequest) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "DeviceUseRequest"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to DeviceUseRequest), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
957794
func (resource *Procedure) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Procedure"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Procedure), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}
344788
func (resource *MedicationAdministration) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "MedicationAdministration"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to MedicationAdministration), 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)
}
88673
func (resource *Specimen) MarshalJSON() ([]byte, error) {
	resource.ResourceType = "Specimen"
	// Dereferencing the pointer to avoid infinite recursion.
	// Passing in plain old x (a pointer to Specimen), would cause this same
	// MarshallJSON function to be called again
	return json.Marshal(*resource)
}