/* 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 { AccessMethodFromJSON, AccessMethodToJSON, } from './AccessMethod';
import { ChecksumFromJSON, ChecksumToJSON, } from './Checksum';
import { ContentFromJSON, ContentToJSON, } from './Content';
/**
 * Check if a given object implements the DrsObject interface.
 */
export function instanceOfDrsObject(value) {
    return true;
}
export function DrsObjectFromJSON(json) {
    return DrsObjectFromJSONTyped(json, false);
}
export function DrsObjectFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'id': json['id'] == null ? undefined : json['id'],
        'name': json['name'] == null ? undefined : json['name'],
        'self_uri': json['self_uri'] == null ? undefined : json['self_uri'],
        'size': json['size'] == null ? undefined : json['size'],
        'created_time': json['created_time'] == null ? undefined : json['created_time'],
        'updated_time': json['updated_time'] == null ? undefined : json['updated_time'],
        'version': json['version'] == null ? undefined : json['version'],
        'mime_type': json['mime_type'] == null ? undefined : json['mime_type'],
        'checksums': json['checksums'] == null ? undefined : (json['checksums'].map(ChecksumFromJSON)),
        'contents': json['contents'] == null ? undefined : (json['contents'].map(ContentFromJSON)),
        'access_methods': json['access_methods'] == null ? undefined : (json['access_methods'].map(AccessMethodFromJSON)),
        'description': json['description'] == null ? undefined : json['description'],
    };
}
export function DrsObjectToJSON(json) {
    return DrsObjectToJSONTyped(json, false);
}
export function DrsObjectToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'id': value['id'],
        'name': value['name'],
        'self_uri': value['self_uri'],
        'size': value['size'],
        'created_time': value['created_time'],
        'updated_time': value['updated_time'],
        'version': value['version'],
        'mime_type': value['mime_type'],
        'checksums': value['checksums'] == null ? undefined : (value['checksums'].map(ChecksumToJSON)),
        'contents': value['contents'] == null ? undefined : (value['contents'].map(ContentToJSON)),
        'access_methods': value['access_methods'] == null ? undefined : (value['access_methods'].map(AccessMethodToJSON)),
        'description': value['description'],
    };
}
//# sourceMappingURL=DrsObject.js.map