// // 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 ScreenConfiguration { /// Returns a new [ScreenConfiguration] instance. ScreenConfiguration({ this.id, this.name, this.type, this.widgets, this.height, this.width, }); String id; String name; String type; List widgets; int height; int width; @override bool operator ==(Object other) => identical(this, other) || other is ScreenConfiguration && other.id == id && other.name == name && other.type == type && other.widgets == widgets && other.height == height && other.width == width; @override int get hashCode => (id == null ? 0 : id.hashCode) + (name == null ? 0 : name.hashCode) + (type == null ? 0 : type.hashCode) + (widgets == null ? 0 : widgets.hashCode) + (height == null ? 0 : height.hashCode) + (width == null ? 0 : width.hashCode); @override String toString() => 'ScreenConfiguration[id=$id, name=$name, type=$type, widgets=$widgets, height=$height, width=$width]'; Map toJson() { final json = {}; if (id != null) { json[r'id'] = id; } if (name != null) { json[r'name'] = name; } if (type != null) { json[r'type'] = type; } if (widgets != null) { json[r'widgets'] = widgets; } if (height != null) { json[r'height'] = height; } if (width != null) { json[r'width'] = width; } return json; } /// Returns a new [ScreenConfiguration] instance and imports its values from /// [json] if it's non-null, null if [json] is null. static ScreenConfiguration fromJson(Map json) => json == null ? null : ScreenConfiguration( id: json[r'id'], name: json[r'name'], type: json[r'type'], widgets: ScreenWidget.listFromJson(json[r'widgets']), height: json[r'height'], width: json[r'width'], ); static List listFromJson(List json, {bool emptyIsNull, bool growable,}) => json == null || json.isEmpty ? true == emptyIsNull ? null : [] : json.map((v) => ScreenConfiguration.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] = ScreenConfiguration.fromJson(v)); } return map; } // maps a json object with a list of ScreenConfiguration-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] = ScreenConfiguration.listFromJson(v, emptyIsNull: emptyIsNull, growable: growable); }); } return map; } }