2023-08-25 06:15:03 +02:00
|
|
|
//
|
|
|
|
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
|
|
|
//
|
2024-05-15 23:52:52 +02:00
|
|
|
// @dart=2.18
|
2023-08-25 06:15:03 +02:00
|
|
|
|
|
|
|
// ignore_for_file: unused_element, unused_import
|
|
|
|
// ignore_for_file: always_put_required_named_parameters_first
|
|
|
|
// ignore_for_file: constant_identifier_names
|
|
|
|
// ignore_for_file: lines_longer_than_80_chars
|
|
|
|
|
|
|
|
part of openapi.api;
|
|
|
|
|
|
|
|
class SystemConfigMachineLearningDto {
|
|
|
|
/// Returns a new [SystemConfigMachineLearningDto] instance.
|
|
|
|
SystemConfigMachineLearningDto({
|
2023-08-29 15:58:00 +02:00
|
|
|
required this.clip,
|
2024-05-16 19:08:37 +02:00
|
|
|
required this.duplicateDetection,
|
2023-08-25 06:15:03 +02:00
|
|
|
required this.enabled,
|
2023-08-29 15:58:00 +02:00
|
|
|
required this.facialRecognition,
|
2023-08-25 06:15:03 +02:00
|
|
|
required this.url,
|
|
|
|
});
|
|
|
|
|
2023-08-29 15:58:00 +02:00
|
|
|
CLIPConfig clip;
|
2023-08-25 06:15:03 +02:00
|
|
|
|
2024-05-16 19:08:37 +02:00
|
|
|
DuplicateDetectionConfig duplicateDetection;
|
|
|
|
|
2023-08-29 15:58:00 +02:00
|
|
|
bool enabled;
|
2023-08-25 06:15:03 +02:00
|
|
|
|
2023-08-29 15:58:00 +02:00
|
|
|
RecognitionConfig facialRecognition;
|
2023-08-25 06:15:03 +02:00
|
|
|
|
|
|
|
String url;
|
|
|
|
|
|
|
|
@override
|
|
|
|
bool operator ==(Object other) => identical(this, other) || other is SystemConfigMachineLearningDto &&
|
2024-01-26 18:40:28 +02:00
|
|
|
other.clip == clip &&
|
2024-05-16 19:08:37 +02:00
|
|
|
other.duplicateDetection == duplicateDetection &&
|
2024-01-26 18:40:28 +02:00
|
|
|
other.enabled == enabled &&
|
|
|
|
other.facialRecognition == facialRecognition &&
|
|
|
|
other.url == url;
|
2023-08-25 06:15:03 +02:00
|
|
|
|
|
|
|
@override
|
|
|
|
int get hashCode =>
|
|
|
|
// ignore: unnecessary_parenthesis
|
2023-08-29 15:58:00 +02:00
|
|
|
(clip.hashCode) +
|
2024-05-16 19:08:37 +02:00
|
|
|
(duplicateDetection.hashCode) +
|
2023-08-25 06:15:03 +02:00
|
|
|
(enabled.hashCode) +
|
2023-08-29 15:58:00 +02:00
|
|
|
(facialRecognition.hashCode) +
|
2023-08-25 06:15:03 +02:00
|
|
|
(url.hashCode);
|
|
|
|
|
|
|
|
@override
|
2024-05-16 19:08:37 +02:00
|
|
|
String toString() => 'SystemConfigMachineLearningDto[clip=$clip, duplicateDetection=$duplicateDetection, enabled=$enabled, facialRecognition=$facialRecognition, url=$url]';
|
2023-08-25 06:15:03 +02:00
|
|
|
|
|
|
|
Map<String, dynamic> toJson() {
|
|
|
|
final json = <String, dynamic>{};
|
2023-08-29 15:58:00 +02:00
|
|
|
json[r'clip'] = this.clip;
|
2024-05-16 19:08:37 +02:00
|
|
|
json[r'duplicateDetection'] = this.duplicateDetection;
|
2023-08-25 06:15:03 +02:00
|
|
|
json[r'enabled'] = this.enabled;
|
2023-08-29 15:58:00 +02:00
|
|
|
json[r'facialRecognition'] = this.facialRecognition;
|
2023-08-25 06:15:03 +02:00
|
|
|
json[r'url'] = this.url;
|
|
|
|
return json;
|
|
|
|
}
|
|
|
|
|
|
|
|
/// Returns a new [SystemConfigMachineLearningDto] instance and imports its values from
|
|
|
|
/// [value] if it's a [Map], null otherwise.
|
|
|
|
// ignore: prefer_constructors_over_static_methods
|
|
|
|
static SystemConfigMachineLearningDto? fromJson(dynamic value) {
|
|
|
|
if (value is Map) {
|
|
|
|
final json = value.cast<String, dynamic>();
|
|
|
|
|
|
|
|
return SystemConfigMachineLearningDto(
|
2023-08-29 15:58:00 +02:00
|
|
|
clip: CLIPConfig.fromJson(json[r'clip'])!,
|
2024-05-16 19:08:37 +02:00
|
|
|
duplicateDetection: DuplicateDetectionConfig.fromJson(json[r'duplicateDetection'])!,
|
2023-08-25 06:15:03 +02:00
|
|
|
enabled: mapValueOfType<bool>(json, r'enabled')!,
|
2023-08-29 15:58:00 +02:00
|
|
|
facialRecognition: RecognitionConfig.fromJson(json[r'facialRecognition'])!,
|
2023-08-25 06:15:03 +02:00
|
|
|
url: mapValueOfType<String>(json, r'url')!,
|
|
|
|
);
|
|
|
|
}
|
|
|
|
return null;
|
|
|
|
}
|
|
|
|
|
|
|
|
static List<SystemConfigMachineLearningDto> listFromJson(dynamic json, {bool growable = false,}) {
|
|
|
|
final result = <SystemConfigMachineLearningDto>[];
|
|
|
|
if (json is List && json.isNotEmpty) {
|
|
|
|
for (final row in json) {
|
|
|
|
final value = SystemConfigMachineLearningDto.fromJson(row);
|
|
|
|
if (value != null) {
|
|
|
|
result.add(value);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return result.toList(growable: growable);
|
|
|
|
}
|
|
|
|
|
|
|
|
static Map<String, SystemConfigMachineLearningDto> mapFromJson(dynamic json) {
|
|
|
|
final map = <String, SystemConfigMachineLearningDto>{};
|
|
|
|
if (json is Map && json.isNotEmpty) {
|
|
|
|
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
|
|
|
for (final entry in json.entries) {
|
|
|
|
final value = SystemConfigMachineLearningDto.fromJson(entry.value);
|
|
|
|
if (value != null) {
|
|
|
|
map[entry.key] = value;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return map;
|
|
|
|
}
|
|
|
|
|
|
|
|
// maps a json object with a list of SystemConfigMachineLearningDto-objects as value to a dart map
|
|
|
|
static Map<String, List<SystemConfigMachineLearningDto>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
|
|
|
final map = <String, List<SystemConfigMachineLearningDto>>{};
|
|
|
|
if (json is Map && json.isNotEmpty) {
|
|
|
|
// ignore: parameter_assignments
|
|
|
|
json = json.cast<String, dynamic>();
|
|
|
|
for (final entry in json.entries) {
|
|
|
|
map[entry.key] = SystemConfigMachineLearningDto.listFromJson(entry.value, growable: growable,);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return map;
|
|
|
|
}
|
|
|
|
|
|
|
|
/// The list of required keys that must be present in a JSON.
|
|
|
|
static const requiredKeys = <String>{
|
2023-08-29 15:58:00 +02:00
|
|
|
'clip',
|
2024-05-16 19:08:37 +02:00
|
|
|
'duplicateDetection',
|
2023-08-25 06:15:03 +02:00
|
|
|
'enabled',
|
2023-08-29 15:58:00 +02:00
|
|
|
'facialRecognition',
|
2023-08-25 06:15:03 +02:00
|
|
|
'url',
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|