/* tslint:disable */
/* eslint-disable */
/**
 * Synapse REST API
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: v1
 *
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */
import { MultipartAttachmentFromJSON, MultipartAttachmentToJSON, } from './MultipartAttachment';
/**
 * Check if a given object implements the MessageBody interface.
 */
export function instanceOfMessageBody(value) {
    return true;
}
export function MessageBodyFromJSON(json) {
    return MessageBodyFromJSONTyped(json, false);
}
export function MessageBodyFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'plain': json['plain'] == null ? undefined : json['plain'],
        'html': json['html'] == null ? undefined : json['html'],
        'attachments': json['attachments'] == null ? undefined : (json['attachments'].map(MultipartAttachmentFromJSON)),
    };
}
export function MessageBodyToJSON(json) {
    return MessageBodyToJSONTyped(json, false);
}
export function MessageBodyToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'plain': value['plain'],
        'html': value['html'],
        'attachments': value['attachments'] == null ? undefined : (value['attachments'].map(MultipartAttachmentToJSON)),
    };
}
//# sourceMappingURL=MessageBody.js.map