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