// // AUTO-GENERATED FILE, DO NOT MODIFY! // // @dart=2.0 // ignore_for_file: unused_element, unused_import // ignore_for_file: always_put_required_named_parameters_first // ignore_for_file: lines_longer_than_80_chars part of openapi.api; class ConfigurationDTO { /// Returns a new [ConfigurationDTO] instance. ConfigurationDTO({ this.id, this.label, this.title, this.imageId, this.imageSource, this.primaryColor, this.secondaryColor, this.languages, this.dateCreation, this.isMobile, this.isTablet, this.isOffline, this.instanceId, }); String id; String label; List title; String imageId; String imageSource; String primaryColor; String secondaryColor; List languages; DateTime dateCreation; bool isMobile; bool isTablet; bool isOffline; String instanceId; @override bool operator ==(Object other) => identical(this, other) || other is ConfigurationDTO && other.id == id && other.label == label && other.title == title && other.imageId == imageId && other.imageSource == imageSource && other.primaryColor == primaryColor && other.secondaryColor == secondaryColor && other.languages == languages && other.dateCreation == dateCreation && other.isMobile == isMobile && other.isTablet == isTablet && other.isOffline == isOffline && other.instanceId == instanceId; @override int get hashCode => (id == null ? 0 : id.hashCode) + (label == null ? 0 : label.hashCode) + (title == null ? 0 : title.hashCode) + (imageId == null ? 0 : imageId.hashCode) + (imageSource == null ? 0 : imageSource.hashCode) + (primaryColor == null ? 0 : primaryColor.hashCode) + (secondaryColor == null ? 0 : secondaryColor.hashCode) + (languages == null ? 0 : languages.hashCode) + (dateCreation == null ? 0 : dateCreation.hashCode) + (isMobile == null ? 0 : isMobile.hashCode) + (isTablet == null ? 0 : isTablet.hashCode) + (isOffline == null ? 0 : isOffline.hashCode) + (instanceId == null ? 0 : instanceId.hashCode); @override String toString() => 'ConfigurationDTO[id=$id, label=$label, title=$title, imageId=$imageId, imageSource=$imageSource, primaryColor=$primaryColor, secondaryColor=$secondaryColor, languages=$languages, dateCreation=$dateCreation, isMobile=$isMobile, isTablet=$isTablet, isOffline=$isOffline, instanceId=$instanceId]'; Map toJson() { final json = {}; if (id != null) { json[r'id'] = id; } if (label != null) { json[r'label'] = label; } if (title != null) { json[r'title'] = title; } if (imageId != null) { json[r'imageId'] = imageId; } if (imageSource != null) { json[r'imageSource'] = imageSource; } if (primaryColor != null) { json[r'primaryColor'] = primaryColor; } if (secondaryColor != null) { json[r'secondaryColor'] = secondaryColor; } if (languages != null) { json[r'languages'] = languages; } if (dateCreation != null) { json[r'dateCreation'] = dateCreation.toUtc().toIso8601String(); } if (isMobile != null) { json[r'isMobile'] = isMobile; } if (isTablet != null) { json[r'isTablet'] = isTablet; } if (isOffline != null) { json[r'isOffline'] = isOffline; } if (instanceId != null) { json[r'instanceId'] = instanceId; } return json; } /// Returns a new [ConfigurationDTO] instance and imports its values from /// [json] if it's non-null, null if [json] is null. static ConfigurationDTO fromJson(Map json) => json == null ? null : ConfigurationDTO( id: json[r'id'], label: json[r'label'], title: TranslationDTO.listFromJson(json[r'title']), imageId: json[r'imageId'], imageSource: json[r'imageSource'], primaryColor: json[r'primaryColor'], secondaryColor: json[r'secondaryColor'], languages: json[r'languages'] == null ? null : (json[r'languages'] as List).cast(), dateCreation: json[r'dateCreation'] == null ? null : DateTime.parse(json[r'dateCreation']), isMobile: json[r'isMobile'], isTablet: json[r'isTablet'], isOffline: json[r'isOffline'], instanceId: json[r'instanceId'], ); static List listFromJson(List json, {bool emptyIsNull, bool growable,}) => json == null || json.isEmpty ? true == emptyIsNull ? null : [] : json.map((v) => ConfigurationDTO.fromJson(v)).toList(growable: true == growable); static Map mapFromJson(Map json) { final map = {}; if (json != null && json.isNotEmpty) { json.forEach((String key, dynamic v) => map[key] = ConfigurationDTO.fromJson(v)); } return map; } // maps a json object with a list of ConfigurationDTO-objects as value to a dart map static Map> mapListFromJson(Map json, {bool emptyIsNull, bool growable,}) { final map = >{}; if (json != null && json.isNotEmpty) { json.forEach((String key, dynamic v) { map[key] = ConfigurationDTO.listFromJson(v, emptyIsNull: emptyIsNull, growable: growable); }); } return map; } }