mirror of
https://github.com/immich-app/immich.git
synced 2026-07-28 22:51:21 -07:00
regen openapi
This commit is contained in:
Generated
+19
@@ -148,6 +148,7 @@ Class | Method | HTTP request | Description
|
||||
*DeprecatedApi* | [**createPartnerDeprecated**](doc//DeprecatedApi.md#createpartnerdeprecated) | **POST** /partners/{id} | Create a partner
|
||||
*DeprecatedApi* | [**getQueuesLegacy**](doc//DeprecatedApi.md#getqueueslegacy) | **GET** /jobs | Retrieve queue counts and status
|
||||
*DeprecatedApi* | [**runQueueCommandLegacy**](doc//DeprecatedApi.md#runqueuecommandlegacy) | **PUT** /jobs/{name} | Run jobs
|
||||
*DeprecatedApi* | [**searchLargeAssets**](doc//DeprecatedApi.md#searchlargeassets) | **POST** /search/large-assets | Search large assets
|
||||
*DeprecatedApi* | [**updateApiKey**](doc//DeprecatedApi.md#updateapikey) | **PUT** /api-keys/{id} | Update an API key
|
||||
*DeprecatedApi* | [**updateAsset**](doc//DeprecatedApi.md#updateasset) | **PUT** /assets/{id} | Update an asset
|
||||
*DeprecatedApi* | [**updateAssets**](doc//DeprecatedApi.md#updateassets) | **PUT** /assets | Update assets
|
||||
@@ -414,6 +415,7 @@ Class | Method | HTTP request | Description
|
||||
- [AudioCodec](doc//AudioCodec.md)
|
||||
- [AuthStatusResponseDto](doc//AuthStatusResponseDto.md)
|
||||
- [AvatarUpdate](doc//AvatarUpdate.md)
|
||||
- [BoolFilter](doc//BoolFilter.md)
|
||||
- [BulkIdErrorReason](doc//BulkIdErrorReason.md)
|
||||
- [BulkIdResponseDto](doc//BulkIdResponseDto.md)
|
||||
- [BulkIdsDto](doc//BulkIdsDto.md)
|
||||
@@ -435,6 +437,8 @@ Class | Method | HTTP request | Description
|
||||
- [DatabaseBackupDeleteDto](doc//DatabaseBackupDeleteDto.md)
|
||||
- [DatabaseBackupDto](doc//DatabaseBackupDto.md)
|
||||
- [DatabaseBackupListResponseDto](doc//DatabaseBackupListResponseDto.md)
|
||||
- [DateFilter](doc//DateFilter.md)
|
||||
- [DateFilterNullable](doc//DateFilterNullable.md)
|
||||
- [DownloadArchiveDto](doc//DownloadArchiveDto.md)
|
||||
- [DownloadArchiveInfo](doc//DownloadArchiveInfo.md)
|
||||
- [DownloadInfoDto](doc//DownloadInfoDto.md)
|
||||
@@ -447,12 +451,17 @@ Class | Method | HTTP request | Description
|
||||
- [DuplicateResponseDto](doc//DuplicateResponseDto.md)
|
||||
- [EmailNotificationsResponse](doc//EmailNotificationsResponse.md)
|
||||
- [EmailNotificationsUpdate](doc//EmailNotificationsUpdate.md)
|
||||
- [EnumFilterAssetType](doc//EnumFilterAssetType.md)
|
||||
- [EnumFilterAssetVisibility](doc//EnumFilterAssetVisibility.md)
|
||||
- [ExifResponseDto](doc//ExifResponseDto.md)
|
||||
- [FaceDto](doc//FaceDto.md)
|
||||
- [FacialRecognitionConfig](doc//FacialRecognitionConfig.md)
|
||||
- [FoldersResponse](doc//FoldersResponse.md)
|
||||
- [FoldersUpdate](doc//FoldersUpdate.md)
|
||||
- [HlsVideoResolution](doc//HlsVideoResolution.md)
|
||||
- [IdFilter](doc//IdFilter.md)
|
||||
- [IdFilterNullable](doc//IdFilterNullable.md)
|
||||
- [IdsFilter](doc//IdsFilter.md)
|
||||
- [ImageFormat](doc//ImageFormat.md)
|
||||
- [IntegrityReport](doc//IntegrityReport.md)
|
||||
- [IntegrityReportResponseDto](doc//IntegrityReportResponseDto.md)
|
||||
@@ -497,6 +506,8 @@ Class | Method | HTTP request | Description
|
||||
- [NotificationType](doc//NotificationType.md)
|
||||
- [NotificationUpdateAllDto](doc//NotificationUpdateAllDto.md)
|
||||
- [NotificationUpdateDto](doc//NotificationUpdateDto.md)
|
||||
- [NumberFilter](doc//NumberFilter.md)
|
||||
- [NumberFilterNullable](doc//NumberFilterNullable.md)
|
||||
- [OAuthAuthorizeResponseDto](doc//OAuthAuthorizeResponseDto.md)
|
||||
- [OAuthCallbackDto](doc//OAuthCallbackDto.md)
|
||||
- [OAuthConfigDto](doc//OAuthConfigDto.md)
|
||||
@@ -559,6 +570,10 @@ Class | Method | HTTP request | Description
|
||||
- [SearchExploreResponseDto](doc//SearchExploreResponseDto.md)
|
||||
- [SearchFacetCountResponseDto](doc//SearchFacetCountResponseDto.md)
|
||||
- [SearchFacetResponseDto](doc//SearchFacetResponseDto.md)
|
||||
- [SearchFilter](doc//SearchFilter.md)
|
||||
- [SearchFilterBranch](doc//SearchFilterBranch.md)
|
||||
- [SearchOrder](doc//SearchOrder.md)
|
||||
- [SearchOrderField](doc//SearchOrderField.md)
|
||||
- [SearchResponseDto](doc//SearchResponseDto.md)
|
||||
- [SearchStatisticsResponseDto](doc//SearchStatisticsResponseDto.md)
|
||||
- [SearchSuggestionType](doc//SearchSuggestionType.md)
|
||||
@@ -593,6 +608,10 @@ Class | Method | HTTP request | Description
|
||||
- [StackUpdateDto](doc//StackUpdateDto.md)
|
||||
- [StatisticsSearchDto](doc//StatisticsSearchDto.md)
|
||||
- [StorageFolder](doc//StorageFolder.md)
|
||||
- [StringFilter](doc//StringFilter.md)
|
||||
- [StringFilterNullable](doc//StringFilterNullable.md)
|
||||
- [StringPatternFilter](doc//StringPatternFilter.md)
|
||||
- [StringSimilarityFilter](doc//StringSimilarityFilter.md)
|
||||
- [SyncAckDeleteDto](doc//SyncAckDeleteDto.md)
|
||||
- [SyncAckDto](doc//SyncAckDto.md)
|
||||
- [SyncAckSetDto](doc//SyncAckSetDto.md)
|
||||
|
||||
Generated
+18
@@ -135,6 +135,7 @@ part 'model/asset_visibility.dart';
|
||||
part 'model/audio_codec.dart';
|
||||
part 'model/auth_status_response_dto.dart';
|
||||
part 'model/avatar_update.dart';
|
||||
part 'model/bool_filter.dart';
|
||||
part 'model/bulk_id_error_reason.dart';
|
||||
part 'model/bulk_id_response_dto.dart';
|
||||
part 'model/bulk_ids_dto.dart';
|
||||
@@ -156,6 +157,8 @@ part 'model/database_backup_config.dart';
|
||||
part 'model/database_backup_delete_dto.dart';
|
||||
part 'model/database_backup_dto.dart';
|
||||
part 'model/database_backup_list_response_dto.dart';
|
||||
part 'model/date_filter.dart';
|
||||
part 'model/date_filter_nullable.dart';
|
||||
part 'model/download_archive_dto.dart';
|
||||
part 'model/download_archive_info.dart';
|
||||
part 'model/download_info_dto.dart';
|
||||
@@ -168,12 +171,17 @@ part 'model/duplicate_resolve_group_dto.dart';
|
||||
part 'model/duplicate_response_dto.dart';
|
||||
part 'model/email_notifications_response.dart';
|
||||
part 'model/email_notifications_update.dart';
|
||||
part 'model/enum_filter_asset_type.dart';
|
||||
part 'model/enum_filter_asset_visibility.dart';
|
||||
part 'model/exif_response_dto.dart';
|
||||
part 'model/face_dto.dart';
|
||||
part 'model/facial_recognition_config.dart';
|
||||
part 'model/folders_response.dart';
|
||||
part 'model/folders_update.dart';
|
||||
part 'model/hls_video_resolution.dart';
|
||||
part 'model/id_filter.dart';
|
||||
part 'model/id_filter_nullable.dart';
|
||||
part 'model/ids_filter.dart';
|
||||
part 'model/image_format.dart';
|
||||
part 'model/integrity_report.dart';
|
||||
part 'model/integrity_report_response_dto.dart';
|
||||
@@ -218,6 +226,8 @@ part 'model/notification_level.dart';
|
||||
part 'model/notification_type.dart';
|
||||
part 'model/notification_update_all_dto.dart';
|
||||
part 'model/notification_update_dto.dart';
|
||||
part 'model/number_filter.dart';
|
||||
part 'model/number_filter_nullable.dart';
|
||||
part 'model/o_auth_authorize_response_dto.dart';
|
||||
part 'model/o_auth_callback_dto.dart';
|
||||
part 'model/o_auth_config_dto.dart';
|
||||
@@ -280,6 +290,10 @@ part 'model/search_explore_item.dart';
|
||||
part 'model/search_explore_response_dto.dart';
|
||||
part 'model/search_facet_count_response_dto.dart';
|
||||
part 'model/search_facet_response_dto.dart';
|
||||
part 'model/search_filter.dart';
|
||||
part 'model/search_filter_branch.dart';
|
||||
part 'model/search_order.dart';
|
||||
part 'model/search_order_field.dart';
|
||||
part 'model/search_response_dto.dart';
|
||||
part 'model/search_statistics_response_dto.dart';
|
||||
part 'model/search_suggestion_type.dart';
|
||||
@@ -314,6 +328,10 @@ part 'model/stack_response_dto.dart';
|
||||
part 'model/stack_update_dto.dart';
|
||||
part 'model/statistics_search_dto.dart';
|
||||
part 'model/storage_folder.dart';
|
||||
part 'model/string_filter.dart';
|
||||
part 'model/string_filter_nullable.dart';
|
||||
part 'model/string_pattern_filter.dart';
|
||||
part 'model/string_similarity_filter.dart';
|
||||
part 'model/sync_ack_delete_dto.dart';
|
||||
part 'model/sync_ack_dto.dart';
|
||||
part 'model/sync_ack_set_dto.dart';
|
||||
|
||||
+332
@@ -185,6 +185,338 @@ class DeprecatedApi {
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Search large assets
|
||||
///
|
||||
/// Search for assets that are considered large based on specified criteria.
|
||||
///
|
||||
/// Note: This method returns the HTTP [Response].
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [List<String>] albumIds:
|
||||
/// Filter by album IDs
|
||||
///
|
||||
/// * [String] city:
|
||||
/// Filter by city name
|
||||
///
|
||||
/// * [String] country:
|
||||
/// Filter by country name
|
||||
///
|
||||
/// * [DateTime] createdAfter:
|
||||
/// Filter by creation date (after)
|
||||
///
|
||||
/// * [DateTime] createdBefore:
|
||||
/// Filter by creation date (before)
|
||||
///
|
||||
/// * [bool] isEncoded:
|
||||
/// Filter by encoded status
|
||||
///
|
||||
/// * [bool] isFavorite:
|
||||
/// Filter by favorite status
|
||||
///
|
||||
/// * [bool] isMotion:
|
||||
/// Filter by motion photo status
|
||||
///
|
||||
/// * [bool] isNotInAlbum:
|
||||
/// Filter assets not in any album
|
||||
///
|
||||
/// * [bool] isOffline:
|
||||
/// Filter by offline status
|
||||
///
|
||||
/// * [String] lensModel:
|
||||
/// Filter by lens model
|
||||
///
|
||||
/// * [String] libraryId:
|
||||
/// Library ID to filter by
|
||||
///
|
||||
/// * [String] make:
|
||||
/// Filter by camera make
|
||||
///
|
||||
/// * [int] minFileSize:
|
||||
/// Minimum file size in bytes
|
||||
///
|
||||
/// * [String] model:
|
||||
/// Filter by camera model
|
||||
///
|
||||
/// * [String] ocr:
|
||||
/// Filter by OCR text content
|
||||
///
|
||||
/// * [List<String>] personIds:
|
||||
/// Filter by person IDs
|
||||
///
|
||||
/// * [int] rating:
|
||||
/// Filter by rating [1-5], or null for unrated
|
||||
///
|
||||
/// * [int] size:
|
||||
/// Number of results to return
|
||||
///
|
||||
/// * [String] state:
|
||||
/// Filter by state/province name
|
||||
///
|
||||
/// * [List<String>] tagIds:
|
||||
/// Filter by tag IDs
|
||||
///
|
||||
/// * [DateTime] takenAfter:
|
||||
/// Filter by taken date (after)
|
||||
///
|
||||
/// * [DateTime] takenBefore:
|
||||
/// Filter by taken date (before)
|
||||
///
|
||||
/// * [DateTime] trashedAfter:
|
||||
/// Filter by trash date (after)
|
||||
///
|
||||
/// * [DateTime] trashedBefore:
|
||||
/// Filter by trash date (before)
|
||||
///
|
||||
/// * [AssetTypeEnum] type:
|
||||
///
|
||||
/// * [DateTime] updatedAfter:
|
||||
/// Filter by update date (after)
|
||||
///
|
||||
/// * [DateTime] updatedBefore:
|
||||
/// Filter by update date (before)
|
||||
///
|
||||
/// * [AssetVisibility] visibility:
|
||||
///
|
||||
/// * [bool] withDeleted:
|
||||
/// Include deleted assets
|
||||
///
|
||||
/// * [bool] withExif:
|
||||
/// Include EXIF data in response
|
||||
Future<Response> searchLargeAssetsWithHttpInfo({ List<String>? albumIds, String? city, String? country, DateTime? createdAfter, DateTime? createdBefore, bool? isEncoded, bool? isFavorite, bool? isMotion, bool? isNotInAlbum, bool? isOffline, String? lensModel, String? libraryId, String? make, int? minFileSize, String? model, String? ocr, List<String>? personIds, int? rating, int? size, String? state, List<String>? tagIds, DateTime? takenAfter, DateTime? takenBefore, DateTime? trashedAfter, DateTime? trashedBefore, AssetTypeEnum? type, DateTime? updatedAfter, DateTime? updatedBefore, AssetVisibility? visibility, bool? withDeleted, bool? withExif, Future<void>? abortTrigger, }) async {
|
||||
// ignore: prefer_const_declarations
|
||||
final apiPath = r'/search/large-assets';
|
||||
|
||||
// ignore: prefer_final_locals
|
||||
Object? postBody;
|
||||
|
||||
final queryParams = <QueryParam>[];
|
||||
final headerParams = <String, String>{};
|
||||
final formParams = <String, String>{};
|
||||
|
||||
if (albumIds != null) {
|
||||
queryParams.addAll(_queryParams('multi', 'albumIds', albumIds));
|
||||
}
|
||||
if (city != null) {
|
||||
queryParams.addAll(_queryParams('', 'city', city));
|
||||
}
|
||||
if (country != null) {
|
||||
queryParams.addAll(_queryParams('', 'country', country));
|
||||
}
|
||||
if (createdAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'createdAfter', createdAfter));
|
||||
}
|
||||
if (createdBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'createdBefore', createdBefore));
|
||||
}
|
||||
if (isEncoded != null) {
|
||||
queryParams.addAll(_queryParams('', 'isEncoded', isEncoded));
|
||||
}
|
||||
if (isFavorite != null) {
|
||||
queryParams.addAll(_queryParams('', 'isFavorite', isFavorite));
|
||||
}
|
||||
if (isMotion != null) {
|
||||
queryParams.addAll(_queryParams('', 'isMotion', isMotion));
|
||||
}
|
||||
if (isNotInAlbum != null) {
|
||||
queryParams.addAll(_queryParams('', 'isNotInAlbum', isNotInAlbum));
|
||||
}
|
||||
if (isOffline != null) {
|
||||
queryParams.addAll(_queryParams('', 'isOffline', isOffline));
|
||||
}
|
||||
if (lensModel != null) {
|
||||
queryParams.addAll(_queryParams('', 'lensModel', lensModel));
|
||||
}
|
||||
if (libraryId != null) {
|
||||
queryParams.addAll(_queryParams('', 'libraryId', libraryId));
|
||||
}
|
||||
if (make != null) {
|
||||
queryParams.addAll(_queryParams('', 'make', make));
|
||||
}
|
||||
if (minFileSize != null) {
|
||||
queryParams.addAll(_queryParams('', 'minFileSize', minFileSize));
|
||||
}
|
||||
if (model != null) {
|
||||
queryParams.addAll(_queryParams('', 'model', model));
|
||||
}
|
||||
if (ocr != null) {
|
||||
queryParams.addAll(_queryParams('', 'ocr', ocr));
|
||||
}
|
||||
if (personIds != null) {
|
||||
queryParams.addAll(_queryParams('multi', 'personIds', personIds));
|
||||
}
|
||||
if (rating != null) {
|
||||
queryParams.addAll(_queryParams('', 'rating', rating));
|
||||
}
|
||||
if (size != null) {
|
||||
queryParams.addAll(_queryParams('', 'size', size));
|
||||
}
|
||||
if (state != null) {
|
||||
queryParams.addAll(_queryParams('', 'state', state));
|
||||
}
|
||||
if (tagIds != null) {
|
||||
queryParams.addAll(_queryParams('multi', 'tagIds', tagIds));
|
||||
}
|
||||
if (takenAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'takenAfter', takenAfter));
|
||||
}
|
||||
if (takenBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'takenBefore', takenBefore));
|
||||
}
|
||||
if (trashedAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'trashedAfter', trashedAfter));
|
||||
}
|
||||
if (trashedBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'trashedBefore', trashedBefore));
|
||||
}
|
||||
if (type != null) {
|
||||
queryParams.addAll(_queryParams('', 'type', type));
|
||||
}
|
||||
if (updatedAfter != null) {
|
||||
queryParams.addAll(_queryParams('', 'updatedAfter', updatedAfter));
|
||||
}
|
||||
if (updatedBefore != null) {
|
||||
queryParams.addAll(_queryParams('', 'updatedBefore', updatedBefore));
|
||||
}
|
||||
if (visibility != null) {
|
||||
queryParams.addAll(_queryParams('', 'visibility', visibility));
|
||||
}
|
||||
if (withDeleted != null) {
|
||||
queryParams.addAll(_queryParams('', 'withDeleted', withDeleted));
|
||||
}
|
||||
if (withExif != null) {
|
||||
queryParams.addAll(_queryParams('', 'withExif', withExif));
|
||||
}
|
||||
|
||||
const contentTypes = <String>[];
|
||||
|
||||
|
||||
return apiClient.invokeAPI(
|
||||
apiPath,
|
||||
'POST',
|
||||
queryParams,
|
||||
postBody,
|
||||
headerParams,
|
||||
formParams,
|
||||
contentTypes.isEmpty ? null : contentTypes.first,
|
||||
abortTrigger: abortTrigger,
|
||||
);
|
||||
}
|
||||
|
||||
/// Search large assets
|
||||
///
|
||||
/// Search for assets that are considered large based on specified criteria.
|
||||
///
|
||||
/// Parameters:
|
||||
///
|
||||
/// * [List<String>] albumIds:
|
||||
/// Filter by album IDs
|
||||
///
|
||||
/// * [String] city:
|
||||
/// Filter by city name
|
||||
///
|
||||
/// * [String] country:
|
||||
/// Filter by country name
|
||||
///
|
||||
/// * [DateTime] createdAfter:
|
||||
/// Filter by creation date (after)
|
||||
///
|
||||
/// * [DateTime] createdBefore:
|
||||
/// Filter by creation date (before)
|
||||
///
|
||||
/// * [bool] isEncoded:
|
||||
/// Filter by encoded status
|
||||
///
|
||||
/// * [bool] isFavorite:
|
||||
/// Filter by favorite status
|
||||
///
|
||||
/// * [bool] isMotion:
|
||||
/// Filter by motion photo status
|
||||
///
|
||||
/// * [bool] isNotInAlbum:
|
||||
/// Filter assets not in any album
|
||||
///
|
||||
/// * [bool] isOffline:
|
||||
/// Filter by offline status
|
||||
///
|
||||
/// * [String] lensModel:
|
||||
/// Filter by lens model
|
||||
///
|
||||
/// * [String] libraryId:
|
||||
/// Library ID to filter by
|
||||
///
|
||||
/// * [String] make:
|
||||
/// Filter by camera make
|
||||
///
|
||||
/// * [int] minFileSize:
|
||||
/// Minimum file size in bytes
|
||||
///
|
||||
/// * [String] model:
|
||||
/// Filter by camera model
|
||||
///
|
||||
/// * [String] ocr:
|
||||
/// Filter by OCR text content
|
||||
///
|
||||
/// * [List<String>] personIds:
|
||||
/// Filter by person IDs
|
||||
///
|
||||
/// * [int] rating:
|
||||
/// Filter by rating [1-5], or null for unrated
|
||||
///
|
||||
/// * [int] size:
|
||||
/// Number of results to return
|
||||
///
|
||||
/// * [String] state:
|
||||
/// Filter by state/province name
|
||||
///
|
||||
/// * [List<String>] tagIds:
|
||||
/// Filter by tag IDs
|
||||
///
|
||||
/// * [DateTime] takenAfter:
|
||||
/// Filter by taken date (after)
|
||||
///
|
||||
/// * [DateTime] takenBefore:
|
||||
/// Filter by taken date (before)
|
||||
///
|
||||
/// * [DateTime] trashedAfter:
|
||||
/// Filter by trash date (after)
|
||||
///
|
||||
/// * [DateTime] trashedBefore:
|
||||
/// Filter by trash date (before)
|
||||
///
|
||||
/// * [AssetTypeEnum] type:
|
||||
///
|
||||
/// * [DateTime] updatedAfter:
|
||||
/// Filter by update date (after)
|
||||
///
|
||||
/// * [DateTime] updatedBefore:
|
||||
/// Filter by update date (before)
|
||||
///
|
||||
/// * [AssetVisibility] visibility:
|
||||
///
|
||||
/// * [bool] withDeleted:
|
||||
/// Include deleted assets
|
||||
///
|
||||
/// * [bool] withExif:
|
||||
/// Include EXIF data in response
|
||||
Future<List<AssetResponseDto>?> searchLargeAssets({ List<String>? albumIds, String? city, String? country, DateTime? createdAfter, DateTime? createdBefore, bool? isEncoded, bool? isFavorite, bool? isMotion, bool? isNotInAlbum, bool? isOffline, String? lensModel, String? libraryId, String? make, int? minFileSize, String? model, String? ocr, List<String>? personIds, int? rating, int? size, String? state, List<String>? tagIds, DateTime? takenAfter, DateTime? takenBefore, DateTime? trashedAfter, DateTime? trashedBefore, AssetTypeEnum? type, DateTime? updatedAfter, DateTime? updatedBefore, AssetVisibility? visibility, bool? withDeleted, bool? withExif, Future<void>? abortTrigger, }) async {
|
||||
final response = await searchLargeAssetsWithHttpInfo(albumIds: albumIds, city: city, country: country, createdAfter: createdAfter, createdBefore: createdBefore, isEncoded: isEncoded, isFavorite: isFavorite, isMotion: isMotion, isNotInAlbum: isNotInAlbum, isOffline: isOffline, lensModel: lensModel, libraryId: libraryId, make: make, minFileSize: minFileSize, model: model, ocr: ocr, personIds: personIds, rating: rating, size: size, state: state, tagIds: tagIds, takenAfter: takenAfter, takenBefore: takenBefore, trashedAfter: trashedAfter, trashedBefore: trashedBefore, type: type, updatedAfter: updatedAfter, updatedBefore: updatedBefore, visibility: visibility, withDeleted: withDeleted, withExif: withExif, abortTrigger: abortTrigger,);
|
||||
if (response.statusCode >= HttpStatus.badRequest) {
|
||||
throw ApiException(response.statusCode, await _decodeBodyBytes(response));
|
||||
}
|
||||
// When a remote server returns no body with a status of 204, we shall not decode it.
|
||||
// At the time of writing this, `dart:convert` will throw an "Unexpected end of input"
|
||||
// FormatException when trying to decode an empty string.
|
||||
if (response.body.isNotEmpty && response.statusCode != HttpStatus.noContent) {
|
||||
final responseBody = await _decodeBodyBytes(response);
|
||||
return (await apiClient.deserializeAsync(responseBody, 'List<AssetResponseDto>') as List)
|
||||
.cast<AssetResponseDto>()
|
||||
.toList(growable: false);
|
||||
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Update an API key
|
||||
///
|
||||
/// Updates the name and permissions of an API key by its ID. The current user must own this API key.
|
||||
|
||||
Generated
+36
@@ -315,6 +315,8 @@ class ApiClient {
|
||||
return AuthStatusResponseDto.fromJson(value);
|
||||
case 'AvatarUpdate':
|
||||
return AvatarUpdate.fromJson(value);
|
||||
case 'BoolFilter':
|
||||
return BoolFilter.fromJson(value);
|
||||
case 'BulkIdErrorReason':
|
||||
return BulkIdErrorReasonTypeTransformer().decode(value);
|
||||
case 'BulkIdResponseDto':
|
||||
@@ -357,6 +359,10 @@ class ApiClient {
|
||||
return DatabaseBackupDto.fromJson(value);
|
||||
case 'DatabaseBackupListResponseDto':
|
||||
return DatabaseBackupListResponseDto.fromJson(value);
|
||||
case 'DateFilter':
|
||||
return DateFilter.fromJson(value);
|
||||
case 'DateFilterNullable':
|
||||
return DateFilterNullable.fromJson(value);
|
||||
case 'DownloadArchiveDto':
|
||||
return DownloadArchiveDto.fromJson(value);
|
||||
case 'DownloadArchiveInfo':
|
||||
@@ -381,6 +387,10 @@ class ApiClient {
|
||||
return EmailNotificationsResponse.fromJson(value);
|
||||
case 'EmailNotificationsUpdate':
|
||||
return EmailNotificationsUpdate.fromJson(value);
|
||||
case 'EnumFilterAssetType':
|
||||
return EnumFilterAssetType.fromJson(value);
|
||||
case 'EnumFilterAssetVisibility':
|
||||
return EnumFilterAssetVisibility.fromJson(value);
|
||||
case 'ExifResponseDto':
|
||||
return ExifResponseDto.fromJson(value);
|
||||
case 'FaceDto':
|
||||
@@ -393,6 +403,12 @@ class ApiClient {
|
||||
return FoldersUpdate.fromJson(value);
|
||||
case 'HlsVideoResolution':
|
||||
return HlsVideoResolutionTypeTransformer().decode(value);
|
||||
case 'IdFilter':
|
||||
return IdFilter.fromJson(value);
|
||||
case 'IdFilterNullable':
|
||||
return IdFilterNullable.fromJson(value);
|
||||
case 'IdsFilter':
|
||||
return IdsFilter.fromJson(value);
|
||||
case 'ImageFormat':
|
||||
return ImageFormatTypeTransformer().decode(value);
|
||||
case 'IntegrityReport':
|
||||
@@ -481,6 +497,10 @@ class ApiClient {
|
||||
return NotificationUpdateAllDto.fromJson(value);
|
||||
case 'NotificationUpdateDto':
|
||||
return NotificationUpdateDto.fromJson(value);
|
||||
case 'NumberFilter':
|
||||
return NumberFilter.fromJson(value);
|
||||
case 'NumberFilterNullable':
|
||||
return NumberFilterNullable.fromJson(value);
|
||||
case 'OAuthAuthorizeResponseDto':
|
||||
return OAuthAuthorizeResponseDto.fromJson(value);
|
||||
case 'OAuthCallbackDto':
|
||||
@@ -605,6 +625,14 @@ class ApiClient {
|
||||
return SearchFacetCountResponseDto.fromJson(value);
|
||||
case 'SearchFacetResponseDto':
|
||||
return SearchFacetResponseDto.fromJson(value);
|
||||
case 'SearchFilter':
|
||||
return SearchFilter.fromJson(value);
|
||||
case 'SearchFilterBranch':
|
||||
return SearchFilterBranch.fromJson(value);
|
||||
case 'SearchOrder':
|
||||
return SearchOrder.fromJson(value);
|
||||
case 'SearchOrderField':
|
||||
return SearchOrderFieldTypeTransformer().decode(value);
|
||||
case 'SearchResponseDto':
|
||||
return SearchResponseDto.fromJson(value);
|
||||
case 'SearchStatisticsResponseDto':
|
||||
@@ -673,6 +701,14 @@ class ApiClient {
|
||||
return StatisticsSearchDto.fromJson(value);
|
||||
case 'StorageFolder':
|
||||
return StorageFolderTypeTransformer().decode(value);
|
||||
case 'StringFilter':
|
||||
return StringFilter.fromJson(value);
|
||||
case 'StringFilterNullable':
|
||||
return StringFilterNullable.fromJson(value);
|
||||
case 'StringPatternFilter':
|
||||
return StringPatternFilter.fromJson(value);
|
||||
case 'StringSimilarityFilter':
|
||||
return StringSimilarityFilter.fromJson(value);
|
||||
case 'SyncAckDeleteDto':
|
||||
return SyncAckDeleteDto.fromJson(value);
|
||||
case 'SyncAckDto':
|
||||
|
||||
Generated
+3
@@ -172,6 +172,9 @@ String parameterToString(dynamic value) {
|
||||
if (value is ReleaseType) {
|
||||
return ReleaseTypeTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is SearchOrderField) {
|
||||
return SearchOrderFieldTypeTransformer().encode(value).toString();
|
||||
}
|
||||
if (value is SearchSuggestionType) {
|
||||
return SearchSuggestionTypeTypeTransformer().encode(value).toString();
|
||||
}
|
||||
|
||||
+99
@@ -0,0 +1,99 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 BoolFilter {
|
||||
/// Returns a new [BoolFilter] instance.
|
||||
BoolFilter({
|
||||
required this.eq,
|
||||
});
|
||||
|
||||
bool eq;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is BoolFilter &&
|
||||
other.eq == eq;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'BoolFilter[eq=$eq]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'eq'] = this.eq;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [BoolFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static BoolFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "BoolFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return BoolFilter(
|
||||
eq: mapValueOfType<bool>(json, r'eq')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<BoolFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <BoolFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = BoolFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, BoolFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, BoolFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = BoolFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of BoolFilter-objects as value to a dart map
|
||||
static Map<String, List<BoolFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<BoolFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = BoolFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'eq',
|
||||
};
|
||||
}
|
||||
|
||||
+199
@@ -0,0 +1,199 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 DateFilter {
|
||||
/// Returns a new [DateFilter] instance.
|
||||
DateFilter({
|
||||
this.eq = const Optional.absent(),
|
||||
this.gt = const Optional.absent(),
|
||||
this.gte = const Optional.absent(),
|
||||
this.lt = const Optional.absent(),
|
||||
this.lte = const Optional.absent(),
|
||||
this.ne = const Optional.absent(),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> eq;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> gt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> gte;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> lt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> lte;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> ne;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is DateFilter &&
|
||||
other.eq == eq &&
|
||||
other.gt == gt &&
|
||||
other.gte == gte &&
|
||||
other.lt == lt &&
|
||||
other.lte == lte &&
|
||||
other.ne == ne;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(gt == null ? 0 : gt!.hashCode) +
|
||||
(gte == null ? 0 : gte!.hashCode) +
|
||||
(lt == null ? 0 : lt!.hashCode) +
|
||||
(lte == null ? 0 : lte!.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'DateFilter[eq=$eq, gt=$gt, gte=$gte, lt=$lt, lte=$lte, ne=$ne]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.gt.isPresent) {
|
||||
final value = this.gt.value;
|
||||
json[r'gt'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.gte.isPresent) {
|
||||
final value = this.gte.value;
|
||||
json[r'gte'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.lt.isPresent) {
|
||||
final value = this.lt.value;
|
||||
json[r'lt'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.lte.isPresent) {
|
||||
final value = this.lte.value;
|
||||
json[r'lte'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [DateFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static DateFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "DateFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return DateFilter(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(mapDateTime(json, r'eq', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
gt: json.containsKey(r'gt') ? Optional.present(mapDateTime(json, r'gt', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
gte: json.containsKey(r'gte') ? Optional.present(mapDateTime(json, r'gte', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
lt: json.containsKey(r'lt') ? Optional.present(mapDateTime(json, r'lt', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
lte: json.containsKey(r'lte') ? Optional.present(mapDateTime(json, r'lte', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(mapDateTime(json, r'ne', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<DateFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <DateFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = DateFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, DateFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, DateFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = DateFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of DateFilter-objects as value to a dart map
|
||||
static Map<String, List<DateFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<DateFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = DateFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+187
@@ -0,0 +1,187 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 DateFilterNullable {
|
||||
/// Returns a new [DateFilterNullable] instance.
|
||||
DateFilterNullable({
|
||||
this.eq = const Optional.absent(),
|
||||
this.gt = const Optional.absent(),
|
||||
this.gte = const Optional.absent(),
|
||||
this.lt = const Optional.absent(),
|
||||
this.lte = const Optional.absent(),
|
||||
this.ne = const Optional.absent(),
|
||||
});
|
||||
|
||||
Optional<DateTime?> eq;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> gt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> gte;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> lt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateTime?> lte;
|
||||
|
||||
Optional<DateTime?> ne;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is DateFilterNullable &&
|
||||
other.eq == eq &&
|
||||
other.gt == gt &&
|
||||
other.gte == gte &&
|
||||
other.lt == lt &&
|
||||
other.lte == lte &&
|
||||
other.ne == ne;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(gt == null ? 0 : gt!.hashCode) +
|
||||
(gte == null ? 0 : gte!.hashCode) +
|
||||
(lt == null ? 0 : lt!.hashCode) +
|
||||
(lte == null ? 0 : lte!.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'DateFilterNullable[eq=$eq, gt=$gt, gte=$gte, lt=$lt, lte=$lte, ne=$ne]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.gt.isPresent) {
|
||||
final value = this.gt.value;
|
||||
json[r'gt'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.gte.isPresent) {
|
||||
final value = this.gte.value;
|
||||
json[r'gte'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.lt.isPresent) {
|
||||
final value = this.lt.value;
|
||||
json[r'lt'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.lte.isPresent) {
|
||||
final value = this.lte.value;
|
||||
json[r'lte'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value == null ? null : (_isEpochMarker(r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [DateFilterNullable] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static DateFilterNullable? fromJson(dynamic value) {
|
||||
upgradeDto(value, "DateFilterNullable");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return DateFilterNullable(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(mapDateTime(json, r'eq', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
gt: json.containsKey(r'gt') ? Optional.present(mapDateTime(json, r'gt', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
gte: json.containsKey(r'gte') ? Optional.present(mapDateTime(json, r'gte', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
lt: json.containsKey(r'lt') ? Optional.present(mapDateTime(json, r'lt', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
lte: json.containsKey(r'lte') ? Optional.present(mapDateTime(json, r'lte', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(mapDateTime(json, r'ne', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<DateFilterNullable> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <DateFilterNullable>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = DateFilterNullable.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, DateFilterNullable> mapFromJson(dynamic json) {
|
||||
final map = <String, DateFilterNullable>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = DateFilterNullable.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of DateFilterNullable-objects as value to a dart map
|
||||
static Map<String, List<DateFilterNullable>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<DateFilterNullable>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = DateFilterNullable.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+143
@@ -0,0 +1,143 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 EnumFilterAssetType {
|
||||
/// Returns a new [EnumFilterAssetType] instance.
|
||||
EnumFilterAssetType({
|
||||
this.eq = const Optional.absent(),
|
||||
this.in_ = const Optional.present(const []),
|
||||
this.ne = const Optional.absent(),
|
||||
this.notIn = const Optional.present(const []),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<AssetTypeEnum?> eq;
|
||||
|
||||
Optional<List<AssetTypeEnum>?> in_;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<AssetTypeEnum?> ne;
|
||||
|
||||
Optional<List<AssetTypeEnum>?> notIn;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is EnumFilterAssetType &&
|
||||
other.eq == eq &&
|
||||
_deepEquality.equals(other.in_, in_) &&
|
||||
other.ne == ne &&
|
||||
_deepEquality.equals(other.notIn, notIn);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(in_.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode) +
|
||||
(notIn.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'EnumFilterAssetType[eq=$eq, in_=$in_, ne=$ne, notIn=$notIn]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.in_.isPresent) {
|
||||
final value = this.in_.value;
|
||||
json[r'in'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
if (this.notIn.isPresent) {
|
||||
final value = this.notIn.value;
|
||||
json[r'notIn'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [EnumFilterAssetType] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static EnumFilterAssetType? fromJson(dynamic value) {
|
||||
upgradeDto(value, "EnumFilterAssetType");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return EnumFilterAssetType(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(AssetTypeEnum.fromJson(json[r'eq'])) : const Optional.absent(),
|
||||
in_: json.containsKey(r'in') ? Optional.present(AssetTypeEnum.listFromJson(json[r'in'])) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(AssetTypeEnum.fromJson(json[r'ne'])) : const Optional.absent(),
|
||||
notIn: json.containsKey(r'notIn') ? Optional.present(AssetTypeEnum.listFromJson(json[r'notIn'])) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<EnumFilterAssetType> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <EnumFilterAssetType>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = EnumFilterAssetType.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, EnumFilterAssetType> mapFromJson(dynamic json) {
|
||||
final map = <String, EnumFilterAssetType>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = EnumFilterAssetType.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of EnumFilterAssetType-objects as value to a dart map
|
||||
static Map<String, List<EnumFilterAssetType>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<EnumFilterAssetType>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = EnumFilterAssetType.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,143 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 EnumFilterAssetVisibility {
|
||||
/// Returns a new [EnumFilterAssetVisibility] instance.
|
||||
EnumFilterAssetVisibility({
|
||||
this.eq = const Optional.absent(),
|
||||
this.in_ = const Optional.present(const []),
|
||||
this.ne = const Optional.absent(),
|
||||
this.notIn = const Optional.present(const []),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<AssetVisibility?> eq;
|
||||
|
||||
Optional<List<AssetVisibility>?> in_;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<AssetVisibility?> ne;
|
||||
|
||||
Optional<List<AssetVisibility>?> notIn;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is EnumFilterAssetVisibility &&
|
||||
other.eq == eq &&
|
||||
_deepEquality.equals(other.in_, in_) &&
|
||||
other.ne == ne &&
|
||||
_deepEquality.equals(other.notIn, notIn);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(in_.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode) +
|
||||
(notIn.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'EnumFilterAssetVisibility[eq=$eq, in_=$in_, ne=$ne, notIn=$notIn]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.in_.isPresent) {
|
||||
final value = this.in_.value;
|
||||
json[r'in'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
if (this.notIn.isPresent) {
|
||||
final value = this.notIn.value;
|
||||
json[r'notIn'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [EnumFilterAssetVisibility] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static EnumFilterAssetVisibility? fromJson(dynamic value) {
|
||||
upgradeDto(value, "EnumFilterAssetVisibility");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return EnumFilterAssetVisibility(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(AssetVisibility.fromJson(json[r'eq'])) : const Optional.absent(),
|
||||
in_: json.containsKey(r'in') ? Optional.present(AssetVisibility.listFromJson(json[r'in'])) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(AssetVisibility.fromJson(json[r'ne'])) : const Optional.absent(),
|
||||
notIn: json.containsKey(r'notIn') ? Optional.present(AssetVisibility.listFromJson(json[r'notIn'])) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<EnumFilterAssetVisibility> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <EnumFilterAssetVisibility>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = EnumFilterAssetVisibility.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, EnumFilterAssetVisibility> mapFromJson(dynamic json) {
|
||||
final map = <String, EnumFilterAssetVisibility>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = EnumFilterAssetVisibility.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of EnumFilterAssetVisibility-objects as value to a dart map
|
||||
static Map<String, List<EnumFilterAssetVisibility>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<EnumFilterAssetVisibility>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = EnumFilterAssetVisibility.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
Generated
+123
@@ -0,0 +1,123 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 IdFilter {
|
||||
/// Returns a new [IdFilter] instance.
|
||||
IdFilter({
|
||||
this.eq = const Optional.absent(),
|
||||
this.ne = const Optional.absent(),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> eq;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> ne;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is IdFilter &&
|
||||
other.eq == eq &&
|
||||
other.ne == ne;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'IdFilter[eq=$eq, ne=$ne]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [IdFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static IdFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "IdFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return IdFilter(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(mapValueOfType<String>(json, r'eq')) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(mapValueOfType<String>(json, r'ne')) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<IdFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <IdFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = IdFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, IdFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, IdFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = IdFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of IdFilter-objects as value to a dart map
|
||||
static Map<String, List<IdFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<IdFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = IdFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+111
@@ -0,0 +1,111 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 IdFilterNullable {
|
||||
/// Returns a new [IdFilterNullable] instance.
|
||||
IdFilterNullable({
|
||||
this.eq = const Optional.absent(),
|
||||
this.ne = const Optional.absent(),
|
||||
});
|
||||
|
||||
Optional<String?> eq;
|
||||
|
||||
Optional<String?> ne;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is IdFilterNullable &&
|
||||
other.eq == eq &&
|
||||
other.ne == ne;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'IdFilterNullable[eq=$eq, ne=$ne]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [IdFilterNullable] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static IdFilterNullable? fromJson(dynamic value) {
|
||||
upgradeDto(value, "IdFilterNullable");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return IdFilterNullable(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(mapValueOfType<String>(json, r'eq')) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(mapValueOfType<String>(json, r'ne')) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<IdFilterNullable> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <IdFilterNullable>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = IdFilterNullable.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, IdFilterNullable> mapFromJson(dynamic json) {
|
||||
final map = <String, IdFilterNullable>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = IdFilterNullable.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of IdFilterNullable-objects as value to a dart map
|
||||
static Map<String, List<IdFilterNullable>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<IdFilterNullable>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = IdFilterNullable.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
Generated
+127
@@ -0,0 +1,127 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 IdsFilter {
|
||||
/// Returns a new [IdsFilter] instance.
|
||||
IdsFilter({
|
||||
this.all = const Optional.present(const []),
|
||||
this.any = const Optional.present(const []),
|
||||
this.none = const Optional.present(const []),
|
||||
});
|
||||
|
||||
Optional<List<String>?> all;
|
||||
|
||||
Optional<List<String>?> any;
|
||||
|
||||
Optional<List<String>?> none;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is IdsFilter &&
|
||||
_deepEquality.equals(other.all, all) &&
|
||||
_deepEquality.equals(other.any, any) &&
|
||||
_deepEquality.equals(other.none, none);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(all.hashCode) +
|
||||
(any.hashCode) +
|
||||
(none.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'IdsFilter[all=$all, any=$any, none=$none]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.all.isPresent) {
|
||||
final value = this.all.value;
|
||||
json[r'all'] = value;
|
||||
}
|
||||
if (this.any.isPresent) {
|
||||
final value = this.any.value;
|
||||
json[r'any'] = value;
|
||||
}
|
||||
if (this.none.isPresent) {
|
||||
final value = this.none.value;
|
||||
json[r'none'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [IdsFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static IdsFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "IdsFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return IdsFilter(
|
||||
all: json.containsKey(r'all') ? Optional.present(json[r'all'] is Iterable
|
||||
? (json[r'all'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
any: json.containsKey(r'any') ? Optional.present(json[r'any'] is Iterable
|
||||
? (json[r'any'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
none: json.containsKey(r'none') ? Optional.present(json[r'none'] is Iterable
|
||||
? (json[r'none'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<IdsFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <IdsFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = IdsFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, IdsFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, IdsFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = IdsFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of IdsFilter-objects as value to a dart map
|
||||
static Map<String, List<IdsFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<IdsFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = IdsFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+50
-1
@@ -19,8 +19,10 @@ class MetadataSearchDto {
|
||||
this.country = const Optional.absent(),
|
||||
this.createdAfter = const Optional.absent(),
|
||||
this.createdBefore = const Optional.absent(),
|
||||
this.cursor = const Optional.absent(),
|
||||
this.description = const Optional.absent(),
|
||||
this.encodedVideoPath = const Optional.absent(),
|
||||
this.filter = const Optional.absent(),
|
||||
this.id = const Optional.absent(),
|
||||
this.isEncoded = const Optional.absent(),
|
||||
this.isFavorite = const Optional.absent(),
|
||||
@@ -33,6 +35,7 @@ class MetadataSearchDto {
|
||||
this.model = const Optional.absent(),
|
||||
this.ocr = const Optional.absent(),
|
||||
this.order = const Optional.absent(),
|
||||
this.orderBy = const Optional.absent(),
|
||||
this.originalFileName = const Optional.absent(),
|
||||
this.originalPath = const Optional.absent(),
|
||||
this.page = const Optional.absent(),
|
||||
@@ -93,6 +96,15 @@ class MetadataSearchDto {
|
||||
///
|
||||
Optional<DateTime?> createdBefore;
|
||||
|
||||
/// Cursor for the next page of results
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> cursor;
|
||||
|
||||
/// Filter by description text
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
@@ -111,6 +123,14 @@ class MetadataSearchDto {
|
||||
///
|
||||
Optional<String?> encodedVideoPath;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<SearchFilter?> filter;
|
||||
|
||||
/// Filter by asset ID
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
@@ -194,6 +214,14 @@ class MetadataSearchDto {
|
||||
///
|
||||
Optional<AssetOrder?> order;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<SearchOrder?> orderBy;
|
||||
|
||||
/// Filter by original file name
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
@@ -383,8 +411,10 @@ class MetadataSearchDto {
|
||||
other.country == country &&
|
||||
other.createdAfter == createdAfter &&
|
||||
other.createdBefore == createdBefore &&
|
||||
other.cursor == cursor &&
|
||||
other.description == description &&
|
||||
other.encodedVideoPath == encodedVideoPath &&
|
||||
other.filter == filter &&
|
||||
other.id == id &&
|
||||
other.isEncoded == isEncoded &&
|
||||
other.isFavorite == isFavorite &&
|
||||
@@ -397,6 +427,7 @@ class MetadataSearchDto {
|
||||
other.model == model &&
|
||||
other.ocr == ocr &&
|
||||
other.order == order &&
|
||||
other.orderBy == orderBy &&
|
||||
other.originalFileName == originalFileName &&
|
||||
other.originalPath == originalPath &&
|
||||
other.page == page &&
|
||||
@@ -429,8 +460,10 @@ class MetadataSearchDto {
|
||||
(country == null ? 0 : country!.hashCode) +
|
||||
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
||||
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
||||
(cursor == null ? 0 : cursor!.hashCode) +
|
||||
(description == null ? 0 : description!.hashCode) +
|
||||
(encodedVideoPath == null ? 0 : encodedVideoPath!.hashCode) +
|
||||
(filter == null ? 0 : filter!.hashCode) +
|
||||
(id == null ? 0 : id!.hashCode) +
|
||||
(isEncoded == null ? 0 : isEncoded!.hashCode) +
|
||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||
@@ -443,6 +476,7 @@ class MetadataSearchDto {
|
||||
(model == null ? 0 : model!.hashCode) +
|
||||
(ocr == null ? 0 : ocr!.hashCode) +
|
||||
(order == null ? 0 : order!.hashCode) +
|
||||
(orderBy == null ? 0 : orderBy!.hashCode) +
|
||||
(originalFileName == null ? 0 : originalFileName!.hashCode) +
|
||||
(originalPath == null ? 0 : originalPath!.hashCode) +
|
||||
(page == null ? 0 : page!.hashCode) +
|
||||
@@ -467,7 +501,7 @@ class MetadataSearchDto {
|
||||
(withStacked == null ? 0 : withStacked!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'MetadataSearchDto[albumIds=$albumIds, checksum=$checksum, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, description=$description, encodedVideoPath=$encodedVideoPath, id=$id, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, order=$order, originalFileName=$originalFileName, originalPath=$originalPath, page=$page, personIds=$personIds, previewPath=$previewPath, rating=$rating, size=$size, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, thumbnailPath=$thumbnailPath, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility, withDeleted=$withDeleted, withExif=$withExif, withPeople=$withPeople, withStacked=$withStacked]';
|
||||
String toString() => 'MetadataSearchDto[albumIds=$albumIds, checksum=$checksum, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, cursor=$cursor, description=$description, encodedVideoPath=$encodedVideoPath, filter=$filter, id=$id, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, order=$order, orderBy=$orderBy, originalFileName=$originalFileName, originalPath=$originalPath, page=$page, personIds=$personIds, previewPath=$previewPath, rating=$rating, size=$size, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, thumbnailPath=$thumbnailPath, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility, withDeleted=$withDeleted, withExif=$withExif, withPeople=$withPeople, withStacked=$withStacked]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -499,6 +533,10 @@ class MetadataSearchDto {
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.cursor.isPresent) {
|
||||
final value = this.cursor.value;
|
||||
json[r'cursor'] = value;
|
||||
}
|
||||
if (this.description.isPresent) {
|
||||
final value = this.description.value;
|
||||
json[r'description'] = value;
|
||||
@@ -507,6 +545,10 @@ class MetadataSearchDto {
|
||||
final value = this.encodedVideoPath.value;
|
||||
json[r'encodedVideoPath'] = value;
|
||||
}
|
||||
if (this.filter.isPresent) {
|
||||
final value = this.filter.value;
|
||||
json[r'filter'] = value;
|
||||
}
|
||||
if (this.id.isPresent) {
|
||||
final value = this.id.value;
|
||||
json[r'id'] = value;
|
||||
@@ -555,6 +597,10 @@ class MetadataSearchDto {
|
||||
final value = this.order.value;
|
||||
json[r'order'] = value;
|
||||
}
|
||||
if (this.orderBy.isPresent) {
|
||||
final value = this.orderBy.value;
|
||||
json[r'orderBy'] = value;
|
||||
}
|
||||
if (this.originalFileName.isPresent) {
|
||||
final value = this.originalFileName.value;
|
||||
json[r'originalFileName'] = value;
|
||||
@@ -675,8 +721,10 @@ class MetadataSearchDto {
|
||||
country: json.containsKey(r'country') ? Optional.present(mapValueOfType<String>(json, r'country')) : const Optional.absent(),
|
||||
createdAfter: json.containsKey(r'createdAfter') ? Optional.present(mapDateTime(json, r'createdAfter', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
createdBefore: json.containsKey(r'createdBefore') ? Optional.present(mapDateTime(json, r'createdBefore', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
cursor: json.containsKey(r'cursor') ? Optional.present(mapValueOfType<String>(json, r'cursor')) : const Optional.absent(),
|
||||
description: json.containsKey(r'description') ? Optional.present(mapValueOfType<String>(json, r'description')) : const Optional.absent(),
|
||||
encodedVideoPath: json.containsKey(r'encodedVideoPath') ? Optional.present(mapValueOfType<String>(json, r'encodedVideoPath')) : const Optional.absent(),
|
||||
filter: json.containsKey(r'filter') ? Optional.present(SearchFilter.fromJson(json[r'filter'])) : const Optional.absent(),
|
||||
id: json.containsKey(r'id') ? Optional.present(mapValueOfType<String>(json, r'id')) : const Optional.absent(),
|
||||
isEncoded: json.containsKey(r'isEncoded') ? Optional.present(mapValueOfType<bool>(json, r'isEncoded')) : const Optional.absent(),
|
||||
isFavorite: json.containsKey(r'isFavorite') ? Optional.present(mapValueOfType<bool>(json, r'isFavorite')) : const Optional.absent(),
|
||||
@@ -689,6 +737,7 @@ class MetadataSearchDto {
|
||||
model: json.containsKey(r'model') ? Optional.present(mapValueOfType<String>(json, r'model')) : const Optional.absent(),
|
||||
ocr: json.containsKey(r'ocr') ? Optional.present(mapValueOfType<String>(json, r'ocr')) : const Optional.absent(),
|
||||
order: json.containsKey(r'order') ? Optional.present(AssetOrder.fromJson(json[r'order'])) : const Optional.absent(),
|
||||
orderBy: json.containsKey(r'orderBy') ? Optional.present(SearchOrder.fromJson(json[r'orderBy'])) : const Optional.absent(),
|
||||
originalFileName: json.containsKey(r'originalFileName') ? Optional.present(mapValueOfType<String>(json, r'originalFileName')) : const Optional.absent(),
|
||||
originalPath: json.containsKey(r'originalPath') ? Optional.present(mapValueOfType<String>(json, r'originalPath')) : const Optional.absent(),
|
||||
page: json.containsKey(r'page') ? Optional.present(json[r'page'] == null ? null : int.parse('${json[r'page']}')) : const Optional.absent(),
|
||||
|
||||
+211
@@ -0,0 +1,211 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 NumberFilter {
|
||||
/// Returns a new [NumberFilter] instance.
|
||||
NumberFilter({
|
||||
this.eq = const Optional.absent(),
|
||||
this.gt = const Optional.absent(),
|
||||
this.gte = const Optional.absent(),
|
||||
this.in_ = const Optional.present(const []),
|
||||
this.lt = const Optional.absent(),
|
||||
this.lte = const Optional.absent(),
|
||||
this.ne = const Optional.absent(),
|
||||
this.notIn = const Optional.present(const []),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> eq;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> gt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> gte;
|
||||
|
||||
Optional<List<num>?> in_;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> lt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> lte;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> ne;
|
||||
|
||||
Optional<List<num>?> notIn;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is NumberFilter &&
|
||||
other.eq == eq &&
|
||||
other.gt == gt &&
|
||||
other.gte == gte &&
|
||||
_deepEquality.equals(other.in_, in_) &&
|
||||
other.lt == lt &&
|
||||
other.lte == lte &&
|
||||
other.ne == ne &&
|
||||
_deepEquality.equals(other.notIn, notIn);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(gt == null ? 0 : gt!.hashCode) +
|
||||
(gte == null ? 0 : gte!.hashCode) +
|
||||
(in_.hashCode) +
|
||||
(lt == null ? 0 : lt!.hashCode) +
|
||||
(lte == null ? 0 : lte!.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode) +
|
||||
(notIn.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'NumberFilter[eq=$eq, gt=$gt, gte=$gte, in_=$in_, lt=$lt, lte=$lte, ne=$ne, notIn=$notIn]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.gt.isPresent) {
|
||||
final value = this.gt.value;
|
||||
json[r'gt'] = value;
|
||||
}
|
||||
if (this.gte.isPresent) {
|
||||
final value = this.gte.value;
|
||||
json[r'gte'] = value;
|
||||
}
|
||||
if (this.in_.isPresent) {
|
||||
final value = this.in_.value;
|
||||
json[r'in'] = value;
|
||||
}
|
||||
if (this.lt.isPresent) {
|
||||
final value = this.lt.value;
|
||||
json[r'lt'] = value;
|
||||
}
|
||||
if (this.lte.isPresent) {
|
||||
final value = this.lte.value;
|
||||
json[r'lte'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
if (this.notIn.isPresent) {
|
||||
final value = this.notIn.value;
|
||||
json[r'notIn'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [NumberFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static NumberFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "NumberFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return NumberFilter(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(json[r'eq'] == null ? null : num.parse('${json[r'eq']}')) : const Optional.absent(),
|
||||
gt: json.containsKey(r'gt') ? Optional.present(json[r'gt'] == null ? null : num.parse('${json[r'gt']}')) : const Optional.absent(),
|
||||
gte: json.containsKey(r'gte') ? Optional.present(json[r'gte'] == null ? null : num.parse('${json[r'gte']}')) : const Optional.absent(),
|
||||
in_: json.containsKey(r'in') ? Optional.present(json[r'in'] is Iterable
|
||||
? (json[r'in'] as Iterable).cast<num>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
lt: json.containsKey(r'lt') ? Optional.present(json[r'lt'] == null ? null : num.parse('${json[r'lt']}')) : const Optional.absent(),
|
||||
lte: json.containsKey(r'lte') ? Optional.present(json[r'lte'] == null ? null : num.parse('${json[r'lte']}')) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(json[r'ne'] == null ? null : num.parse('${json[r'ne']}')) : const Optional.absent(),
|
||||
notIn: json.containsKey(r'notIn') ? Optional.present(json[r'notIn'] is Iterable
|
||||
? (json[r'notIn'] as Iterable).cast<num>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<NumberFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <NumberFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = NumberFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, NumberFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, NumberFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = NumberFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of NumberFilter-objects as value to a dart map
|
||||
static Map<String, List<NumberFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<NumberFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = NumberFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+199
@@ -0,0 +1,199 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 NumberFilterNullable {
|
||||
/// Returns a new [NumberFilterNullable] instance.
|
||||
NumberFilterNullable({
|
||||
this.eq = const Optional.absent(),
|
||||
this.gt = const Optional.absent(),
|
||||
this.gte = const Optional.absent(),
|
||||
this.in_ = const Optional.present(const []),
|
||||
this.lt = const Optional.absent(),
|
||||
this.lte = const Optional.absent(),
|
||||
this.ne = const Optional.absent(),
|
||||
this.notIn = const Optional.present(const []),
|
||||
});
|
||||
|
||||
Optional<num?> eq;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> gt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> gte;
|
||||
|
||||
Optional<List<num>?> in_;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> lt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<num?> lte;
|
||||
|
||||
Optional<num?> ne;
|
||||
|
||||
Optional<List<num>?> notIn;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is NumberFilterNullable &&
|
||||
other.eq == eq &&
|
||||
other.gt == gt &&
|
||||
other.gte == gte &&
|
||||
_deepEquality.equals(other.in_, in_) &&
|
||||
other.lt == lt &&
|
||||
other.lte == lte &&
|
||||
other.ne == ne &&
|
||||
_deepEquality.equals(other.notIn, notIn);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(gt == null ? 0 : gt!.hashCode) +
|
||||
(gte == null ? 0 : gte!.hashCode) +
|
||||
(in_.hashCode) +
|
||||
(lt == null ? 0 : lt!.hashCode) +
|
||||
(lte == null ? 0 : lte!.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode) +
|
||||
(notIn.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'NumberFilterNullable[eq=$eq, gt=$gt, gte=$gte, in_=$in_, lt=$lt, lte=$lte, ne=$ne, notIn=$notIn]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.gt.isPresent) {
|
||||
final value = this.gt.value;
|
||||
json[r'gt'] = value;
|
||||
}
|
||||
if (this.gte.isPresent) {
|
||||
final value = this.gte.value;
|
||||
json[r'gte'] = value;
|
||||
}
|
||||
if (this.in_.isPresent) {
|
||||
final value = this.in_.value;
|
||||
json[r'in'] = value;
|
||||
}
|
||||
if (this.lt.isPresent) {
|
||||
final value = this.lt.value;
|
||||
json[r'lt'] = value;
|
||||
}
|
||||
if (this.lte.isPresent) {
|
||||
final value = this.lte.value;
|
||||
json[r'lte'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
if (this.notIn.isPresent) {
|
||||
final value = this.notIn.value;
|
||||
json[r'notIn'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [NumberFilterNullable] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static NumberFilterNullable? fromJson(dynamic value) {
|
||||
upgradeDto(value, "NumberFilterNullable");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return NumberFilterNullable(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(json[r'eq'] == null ? null : num.parse('${json[r'eq']}')) : const Optional.absent(),
|
||||
gt: json.containsKey(r'gt') ? Optional.present(json[r'gt'] == null ? null : num.parse('${json[r'gt']}')) : const Optional.absent(),
|
||||
gte: json.containsKey(r'gte') ? Optional.present(json[r'gte'] == null ? null : num.parse('${json[r'gte']}')) : const Optional.absent(),
|
||||
in_: json.containsKey(r'in') ? Optional.present(json[r'in'] is Iterable
|
||||
? (json[r'in'] as Iterable).cast<num>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
lt: json.containsKey(r'lt') ? Optional.present(json[r'lt'] == null ? null : num.parse('${json[r'lt']}')) : const Optional.absent(),
|
||||
lte: json.containsKey(r'lte') ? Optional.present(json[r'lte'] == null ? null : num.parse('${json[r'lte']}')) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(json[r'ne'] == null ? null : num.parse('${json[r'ne']}')) : const Optional.absent(),
|
||||
notIn: json.containsKey(r'notIn') ? Optional.present(json[r'notIn'] is Iterable
|
||||
? (json[r'notIn'] as Iterable).cast<num>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<NumberFilterNullable> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <NumberFilterNullable>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = NumberFilterNullable.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, NumberFilterNullable> mapFromJson(dynamic json) {
|
||||
final map = <String, NumberFilterNullable>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = NumberFilterNullable.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of NumberFilterNullable-objects as value to a dart map
|
||||
static Map<String, List<NumberFilterNullable>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<NumberFilterNullable>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = NumberFilterNullable.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+17
-1
@@ -18,6 +18,7 @@ class RandomSearchDto {
|
||||
this.country = const Optional.absent(),
|
||||
this.createdAfter = const Optional.absent(),
|
||||
this.createdBefore = const Optional.absent(),
|
||||
this.filter = const Optional.absent(),
|
||||
this.isEncoded = const Optional.absent(),
|
||||
this.isFavorite = const Optional.absent(),
|
||||
this.isMotion = const Optional.absent(),
|
||||
@@ -74,6 +75,14 @@ class RandomSearchDto {
|
||||
///
|
||||
Optional<DateTime?> createdBefore;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<SearchFilter?> filter;
|
||||
|
||||
/// Filter by encoded status
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
@@ -280,6 +289,7 @@ class RandomSearchDto {
|
||||
other.country == country &&
|
||||
other.createdAfter == createdAfter &&
|
||||
other.createdBefore == createdBefore &&
|
||||
other.filter == filter &&
|
||||
other.isEncoded == isEncoded &&
|
||||
other.isFavorite == isFavorite &&
|
||||
other.isMotion == isMotion &&
|
||||
@@ -316,6 +326,7 @@ class RandomSearchDto {
|
||||
(country == null ? 0 : country!.hashCode) +
|
||||
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
||||
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
||||
(filter == null ? 0 : filter!.hashCode) +
|
||||
(isEncoded == null ? 0 : isEncoded!.hashCode) +
|
||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||
(isMotion == null ? 0 : isMotion!.hashCode) +
|
||||
@@ -345,7 +356,7 @@ class RandomSearchDto {
|
||||
(withStacked == null ? 0 : withStacked!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'RandomSearchDto[albumIds=$albumIds, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, personIds=$personIds, rating=$rating, size=$size, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility, withDeleted=$withDeleted, withExif=$withExif, withPeople=$withPeople, withStacked=$withStacked]';
|
||||
String toString() => 'RandomSearchDto[albumIds=$albumIds, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, filter=$filter, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, personIds=$personIds, rating=$rating, size=$size, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility, withDeleted=$withDeleted, withExif=$withExif, withPeople=$withPeople, withStacked=$withStacked]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -373,6 +384,10 @@ class RandomSearchDto {
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.filter.isPresent) {
|
||||
final value = this.filter.value;
|
||||
json[r'filter'] = value;
|
||||
}
|
||||
if (this.isEncoded.isPresent) {
|
||||
final value = this.isEncoded.value;
|
||||
json[r'isEncoded'] = value;
|
||||
@@ -512,6 +527,7 @@ class RandomSearchDto {
|
||||
country: json.containsKey(r'country') ? Optional.present(mapValueOfType<String>(json, r'country')) : const Optional.absent(),
|
||||
createdAfter: json.containsKey(r'createdAfter') ? Optional.present(mapDateTime(json, r'createdAfter', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
createdBefore: json.containsKey(r'createdBefore') ? Optional.present(mapDateTime(json, r'createdBefore', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
filter: json.containsKey(r'filter') ? Optional.present(SearchFilter.fromJson(json[r'filter'])) : const Optional.absent(),
|
||||
isEncoded: json.containsKey(r'isEncoded') ? Optional.present(mapValueOfType<bool>(json, r'isEncoded')) : const Optional.absent(),
|
||||
isFavorite: json.containsKey(r'isFavorite') ? Optional.present(mapValueOfType<bool>(json, r'isFavorite')) : const Optional.absent(),
|
||||
isMotion: json.containsKey(r'isMotion') ? Optional.present(mapValueOfType<bool>(json, r'isMotion')) : const Optional.absent(),
|
||||
|
||||
+14
-1
@@ -16,6 +16,7 @@ class SearchAssetResponseDto {
|
||||
required this.count,
|
||||
this.facets = const [],
|
||||
this.items = const [],
|
||||
required this.nextCursor,
|
||||
required this.nextPage,
|
||||
required this.total,
|
||||
});
|
||||
@@ -30,6 +31,9 @@ class SearchAssetResponseDto {
|
||||
|
||||
List<AssetResponseDto> items;
|
||||
|
||||
/// Cursor for the next page of results
|
||||
String? nextCursor;
|
||||
|
||||
/// Next page token
|
||||
String? nextPage;
|
||||
|
||||
@@ -44,6 +48,7 @@ class SearchAssetResponseDto {
|
||||
other.count == count &&
|
||||
_deepEquality.equals(other.facets, facets) &&
|
||||
_deepEquality.equals(other.items, items) &&
|
||||
other.nextCursor == nextCursor &&
|
||||
other.nextPage == nextPage &&
|
||||
other.total == total;
|
||||
|
||||
@@ -53,17 +58,23 @@ class SearchAssetResponseDto {
|
||||
(count.hashCode) +
|
||||
(facets.hashCode) +
|
||||
(items.hashCode) +
|
||||
(nextCursor == null ? 0 : nextCursor!.hashCode) +
|
||||
(nextPage == null ? 0 : nextPage!.hashCode) +
|
||||
(total.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SearchAssetResponseDto[count=$count, facets=$facets, items=$items, nextPage=$nextPage, total=$total]';
|
||||
String toString() => 'SearchAssetResponseDto[count=$count, facets=$facets, items=$items, nextCursor=$nextCursor, nextPage=$nextPage, total=$total]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'count'] = this.count;
|
||||
json[r'facets'] = this.facets;
|
||||
json[r'items'] = this.items;
|
||||
if (this.nextCursor != null) {
|
||||
json[r'nextCursor'] = this.nextCursor;
|
||||
} else {
|
||||
json[r'nextCursor'] = null;
|
||||
}
|
||||
if (this.nextPage != null) {
|
||||
json[r'nextPage'] = this.nextPage;
|
||||
} else {
|
||||
@@ -85,6 +96,7 @@ class SearchAssetResponseDto {
|
||||
count: mapValueOfType<int>(json, r'count')!,
|
||||
facets: SearchFacetResponseDto.listFromJson(json[r'facets']),
|
||||
items: AssetResponseDto.listFromJson(json[r'items']),
|
||||
nextCursor: mapValueOfType<String>(json, r'nextCursor'),
|
||||
nextPage: mapValueOfType<String>(json, r'nextPage'),
|
||||
total: mapValueOfType<int>(json, r'total')!,
|
||||
);
|
||||
@@ -137,6 +149,7 @@ class SearchAssetResponseDto {
|
||||
'count',
|
||||
'facets',
|
||||
'items',
|
||||
'nextCursor',
|
||||
'nextPage',
|
||||
'total',
|
||||
};
|
||||
|
||||
+613
@@ -0,0 +1,613 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 SearchFilter {
|
||||
/// Returns a new [SearchFilter] instance.
|
||||
SearchFilter({
|
||||
this.albumIds = const Optional.absent(),
|
||||
this.checksum = const Optional.absent(),
|
||||
this.city = const Optional.absent(),
|
||||
this.country = const Optional.absent(),
|
||||
this.createdAt = const Optional.absent(),
|
||||
this.description = const Optional.absent(),
|
||||
this.encodedVideoPath = const Optional.absent(),
|
||||
this.fileSizeInBytes = const Optional.absent(),
|
||||
this.hasAlbums = const Optional.absent(),
|
||||
this.hasPeople = const Optional.absent(),
|
||||
this.hasTags = const Optional.absent(),
|
||||
this.id = const Optional.absent(),
|
||||
this.isEncoded = const Optional.absent(),
|
||||
this.isFavorite = const Optional.absent(),
|
||||
this.isMotion = const Optional.absent(),
|
||||
this.isOffline = const Optional.absent(),
|
||||
this.lensModel = const Optional.absent(),
|
||||
this.libraryId = const Optional.absent(),
|
||||
this.make = const Optional.absent(),
|
||||
this.model = const Optional.absent(),
|
||||
this.ocr = const Optional.absent(),
|
||||
this.or = const Optional.present(const []),
|
||||
this.originalFileName = const Optional.absent(),
|
||||
this.originalPath = const Optional.absent(),
|
||||
this.personIds = const Optional.absent(),
|
||||
this.rating = const Optional.absent(),
|
||||
this.state = const Optional.absent(),
|
||||
this.tagIds = const Optional.absent(),
|
||||
this.takenAt = const Optional.absent(),
|
||||
this.trashedAt = const Optional.absent(),
|
||||
this.type = const Optional.absent(),
|
||||
this.updatedAt = const Optional.absent(),
|
||||
this.visibility = const Optional.absent(),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdsFilter?> albumIds;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilter?> checksum;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> city;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> country;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateFilter?> createdAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringPatternFilter?> description;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilter?> encodedVideoPath;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<NumberFilter?> fileSizeInBytes;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> hasAlbums;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> hasPeople;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> hasTags;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdFilter?> id;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> isEncoded;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> isFavorite;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> isMotion;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> isOffline;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> lensModel;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdFilterNullable?> libraryId;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> make;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> model;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringSimilarityFilter?> ocr;
|
||||
|
||||
Optional<List<SearchFilterBranch>?> or;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringPatternFilter?> originalFileName;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringPatternFilter?> originalPath;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdsFilter?> personIds;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<NumberFilterNullable?> rating;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> state;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdsFilter?> tagIds;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateFilter?> takenAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateFilterNullable?> trashedAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<EnumFilterAssetType?> type;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateFilter?> updatedAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<EnumFilterAssetVisibility?> visibility;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SearchFilter &&
|
||||
other.albumIds == albumIds &&
|
||||
other.checksum == checksum &&
|
||||
other.city == city &&
|
||||
other.country == country &&
|
||||
other.createdAt == createdAt &&
|
||||
other.description == description &&
|
||||
other.encodedVideoPath == encodedVideoPath &&
|
||||
other.fileSizeInBytes == fileSizeInBytes &&
|
||||
other.hasAlbums == hasAlbums &&
|
||||
other.hasPeople == hasPeople &&
|
||||
other.hasTags == hasTags &&
|
||||
other.id == id &&
|
||||
other.isEncoded == isEncoded &&
|
||||
other.isFavorite == isFavorite &&
|
||||
other.isMotion == isMotion &&
|
||||
other.isOffline == isOffline &&
|
||||
other.lensModel == lensModel &&
|
||||
other.libraryId == libraryId &&
|
||||
other.make == make &&
|
||||
other.model == model &&
|
||||
other.ocr == ocr &&
|
||||
_deepEquality.equals(other.or, or) &&
|
||||
other.originalFileName == originalFileName &&
|
||||
other.originalPath == originalPath &&
|
||||
other.personIds == personIds &&
|
||||
other.rating == rating &&
|
||||
other.state == state &&
|
||||
other.tagIds == tagIds &&
|
||||
other.takenAt == takenAt &&
|
||||
other.trashedAt == trashedAt &&
|
||||
other.type == type &&
|
||||
other.updatedAt == updatedAt &&
|
||||
other.visibility == visibility;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(albumIds == null ? 0 : albumIds!.hashCode) +
|
||||
(checksum == null ? 0 : checksum!.hashCode) +
|
||||
(city == null ? 0 : city!.hashCode) +
|
||||
(country == null ? 0 : country!.hashCode) +
|
||||
(createdAt == null ? 0 : createdAt!.hashCode) +
|
||||
(description == null ? 0 : description!.hashCode) +
|
||||
(encodedVideoPath == null ? 0 : encodedVideoPath!.hashCode) +
|
||||
(fileSizeInBytes == null ? 0 : fileSizeInBytes!.hashCode) +
|
||||
(hasAlbums == null ? 0 : hasAlbums!.hashCode) +
|
||||
(hasPeople == null ? 0 : hasPeople!.hashCode) +
|
||||
(hasTags == null ? 0 : hasTags!.hashCode) +
|
||||
(id == null ? 0 : id!.hashCode) +
|
||||
(isEncoded == null ? 0 : isEncoded!.hashCode) +
|
||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||
(isMotion == null ? 0 : isMotion!.hashCode) +
|
||||
(isOffline == null ? 0 : isOffline!.hashCode) +
|
||||
(lensModel == null ? 0 : lensModel!.hashCode) +
|
||||
(libraryId == null ? 0 : libraryId!.hashCode) +
|
||||
(make == null ? 0 : make!.hashCode) +
|
||||
(model == null ? 0 : model!.hashCode) +
|
||||
(ocr == null ? 0 : ocr!.hashCode) +
|
||||
(or.hashCode) +
|
||||
(originalFileName == null ? 0 : originalFileName!.hashCode) +
|
||||
(originalPath == null ? 0 : originalPath!.hashCode) +
|
||||
(personIds == null ? 0 : personIds!.hashCode) +
|
||||
(rating == null ? 0 : rating!.hashCode) +
|
||||
(state == null ? 0 : state!.hashCode) +
|
||||
(tagIds == null ? 0 : tagIds!.hashCode) +
|
||||
(takenAt == null ? 0 : takenAt!.hashCode) +
|
||||
(trashedAt == null ? 0 : trashedAt!.hashCode) +
|
||||
(type == null ? 0 : type!.hashCode) +
|
||||
(updatedAt == null ? 0 : updatedAt!.hashCode) +
|
||||
(visibility == null ? 0 : visibility!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SearchFilter[albumIds=$albumIds, checksum=$checksum, city=$city, country=$country, createdAt=$createdAt, description=$description, encodedVideoPath=$encodedVideoPath, fileSizeInBytes=$fileSizeInBytes, hasAlbums=$hasAlbums, hasPeople=$hasPeople, hasTags=$hasTags, id=$id, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isOffline=$isOffline, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, or=$or, originalFileName=$originalFileName, originalPath=$originalPath, personIds=$personIds, rating=$rating, state=$state, tagIds=$tagIds, takenAt=$takenAt, trashedAt=$trashedAt, type=$type, updatedAt=$updatedAt, visibility=$visibility]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.albumIds.isPresent) {
|
||||
final value = this.albumIds.value;
|
||||
json[r'albumIds'] = value;
|
||||
}
|
||||
if (this.checksum.isPresent) {
|
||||
final value = this.checksum.value;
|
||||
json[r'checksum'] = value;
|
||||
}
|
||||
if (this.city.isPresent) {
|
||||
final value = this.city.value;
|
||||
json[r'city'] = value;
|
||||
}
|
||||
if (this.country.isPresent) {
|
||||
final value = this.country.value;
|
||||
json[r'country'] = value;
|
||||
}
|
||||
if (this.createdAt.isPresent) {
|
||||
final value = this.createdAt.value;
|
||||
json[r'createdAt'] = value;
|
||||
}
|
||||
if (this.description.isPresent) {
|
||||
final value = this.description.value;
|
||||
json[r'description'] = value;
|
||||
}
|
||||
if (this.encodedVideoPath.isPresent) {
|
||||
final value = this.encodedVideoPath.value;
|
||||
json[r'encodedVideoPath'] = value;
|
||||
}
|
||||
if (this.fileSizeInBytes.isPresent) {
|
||||
final value = this.fileSizeInBytes.value;
|
||||
json[r'fileSizeInBytes'] = value;
|
||||
}
|
||||
if (this.hasAlbums.isPresent) {
|
||||
final value = this.hasAlbums.value;
|
||||
json[r'hasAlbums'] = value;
|
||||
}
|
||||
if (this.hasPeople.isPresent) {
|
||||
final value = this.hasPeople.value;
|
||||
json[r'hasPeople'] = value;
|
||||
}
|
||||
if (this.hasTags.isPresent) {
|
||||
final value = this.hasTags.value;
|
||||
json[r'hasTags'] = value;
|
||||
}
|
||||
if (this.id.isPresent) {
|
||||
final value = this.id.value;
|
||||
json[r'id'] = value;
|
||||
}
|
||||
if (this.isEncoded.isPresent) {
|
||||
final value = this.isEncoded.value;
|
||||
json[r'isEncoded'] = value;
|
||||
}
|
||||
if (this.isFavorite.isPresent) {
|
||||
final value = this.isFavorite.value;
|
||||
json[r'isFavorite'] = value;
|
||||
}
|
||||
if (this.isMotion.isPresent) {
|
||||
final value = this.isMotion.value;
|
||||
json[r'isMotion'] = value;
|
||||
}
|
||||
if (this.isOffline.isPresent) {
|
||||
final value = this.isOffline.value;
|
||||
json[r'isOffline'] = value;
|
||||
}
|
||||
if (this.lensModel.isPresent) {
|
||||
final value = this.lensModel.value;
|
||||
json[r'lensModel'] = value;
|
||||
}
|
||||
if (this.libraryId.isPresent) {
|
||||
final value = this.libraryId.value;
|
||||
json[r'libraryId'] = value;
|
||||
}
|
||||
if (this.make.isPresent) {
|
||||
final value = this.make.value;
|
||||
json[r'make'] = value;
|
||||
}
|
||||
if (this.model.isPresent) {
|
||||
final value = this.model.value;
|
||||
json[r'model'] = value;
|
||||
}
|
||||
if (this.ocr.isPresent) {
|
||||
final value = this.ocr.value;
|
||||
json[r'ocr'] = value;
|
||||
}
|
||||
if (this.or.isPresent) {
|
||||
final value = this.or.value;
|
||||
json[r'or'] = value;
|
||||
}
|
||||
if (this.originalFileName.isPresent) {
|
||||
final value = this.originalFileName.value;
|
||||
json[r'originalFileName'] = value;
|
||||
}
|
||||
if (this.originalPath.isPresent) {
|
||||
final value = this.originalPath.value;
|
||||
json[r'originalPath'] = value;
|
||||
}
|
||||
if (this.personIds.isPresent) {
|
||||
final value = this.personIds.value;
|
||||
json[r'personIds'] = value;
|
||||
}
|
||||
if (this.rating.isPresent) {
|
||||
final value = this.rating.value;
|
||||
json[r'rating'] = value;
|
||||
}
|
||||
if (this.state.isPresent) {
|
||||
final value = this.state.value;
|
||||
json[r'state'] = value;
|
||||
}
|
||||
if (this.tagIds.isPresent) {
|
||||
final value = this.tagIds.value;
|
||||
json[r'tagIds'] = value;
|
||||
}
|
||||
if (this.takenAt.isPresent) {
|
||||
final value = this.takenAt.value;
|
||||
json[r'takenAt'] = value;
|
||||
}
|
||||
if (this.trashedAt.isPresent) {
|
||||
final value = this.trashedAt.value;
|
||||
json[r'trashedAt'] = value;
|
||||
}
|
||||
if (this.type.isPresent) {
|
||||
final value = this.type.value;
|
||||
json[r'type'] = value;
|
||||
}
|
||||
if (this.updatedAt.isPresent) {
|
||||
final value = this.updatedAt.value;
|
||||
json[r'updatedAt'] = value;
|
||||
}
|
||||
if (this.visibility.isPresent) {
|
||||
final value = this.visibility.value;
|
||||
json[r'visibility'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [SearchFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static SearchFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "SearchFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SearchFilter(
|
||||
albumIds: json.containsKey(r'albumIds') ? Optional.present(IdsFilter.fromJson(json[r'albumIds'])) : const Optional.absent(),
|
||||
checksum: json.containsKey(r'checksum') ? Optional.present(StringFilter.fromJson(json[r'checksum'])) : const Optional.absent(),
|
||||
city: json.containsKey(r'city') ? Optional.present(StringFilterNullable.fromJson(json[r'city'])) : const Optional.absent(),
|
||||
country: json.containsKey(r'country') ? Optional.present(StringFilterNullable.fromJson(json[r'country'])) : const Optional.absent(),
|
||||
createdAt: json.containsKey(r'createdAt') ? Optional.present(DateFilter.fromJson(json[r'createdAt'])) : const Optional.absent(),
|
||||
description: json.containsKey(r'description') ? Optional.present(StringPatternFilter.fromJson(json[r'description'])) : const Optional.absent(),
|
||||
encodedVideoPath: json.containsKey(r'encodedVideoPath') ? Optional.present(StringFilter.fromJson(json[r'encodedVideoPath'])) : const Optional.absent(),
|
||||
fileSizeInBytes: json.containsKey(r'fileSizeInBytes') ? Optional.present(NumberFilter.fromJson(json[r'fileSizeInBytes'])) : const Optional.absent(),
|
||||
hasAlbums: json.containsKey(r'hasAlbums') ? Optional.present(BoolFilter.fromJson(json[r'hasAlbums'])) : const Optional.absent(),
|
||||
hasPeople: json.containsKey(r'hasPeople') ? Optional.present(BoolFilter.fromJson(json[r'hasPeople'])) : const Optional.absent(),
|
||||
hasTags: json.containsKey(r'hasTags') ? Optional.present(BoolFilter.fromJson(json[r'hasTags'])) : const Optional.absent(),
|
||||
id: json.containsKey(r'id') ? Optional.present(IdFilter.fromJson(json[r'id'])) : const Optional.absent(),
|
||||
isEncoded: json.containsKey(r'isEncoded') ? Optional.present(BoolFilter.fromJson(json[r'isEncoded'])) : const Optional.absent(),
|
||||
isFavorite: json.containsKey(r'isFavorite') ? Optional.present(BoolFilter.fromJson(json[r'isFavorite'])) : const Optional.absent(),
|
||||
isMotion: json.containsKey(r'isMotion') ? Optional.present(BoolFilter.fromJson(json[r'isMotion'])) : const Optional.absent(),
|
||||
isOffline: json.containsKey(r'isOffline') ? Optional.present(BoolFilter.fromJson(json[r'isOffline'])) : const Optional.absent(),
|
||||
lensModel: json.containsKey(r'lensModel') ? Optional.present(StringFilterNullable.fromJson(json[r'lensModel'])) : const Optional.absent(),
|
||||
libraryId: json.containsKey(r'libraryId') ? Optional.present(IdFilterNullable.fromJson(json[r'libraryId'])) : const Optional.absent(),
|
||||
make: json.containsKey(r'make') ? Optional.present(StringFilterNullable.fromJson(json[r'make'])) : const Optional.absent(),
|
||||
model: json.containsKey(r'model') ? Optional.present(StringFilterNullable.fromJson(json[r'model'])) : const Optional.absent(),
|
||||
ocr: json.containsKey(r'ocr') ? Optional.present(StringSimilarityFilter.fromJson(json[r'ocr'])) : const Optional.absent(),
|
||||
or: json.containsKey(r'or') ? Optional.present(SearchFilterBranch.listFromJson(json[r'or'])) : const Optional.absent(),
|
||||
originalFileName: json.containsKey(r'originalFileName') ? Optional.present(StringPatternFilter.fromJson(json[r'originalFileName'])) : const Optional.absent(),
|
||||
originalPath: json.containsKey(r'originalPath') ? Optional.present(StringPatternFilter.fromJson(json[r'originalPath'])) : const Optional.absent(),
|
||||
personIds: json.containsKey(r'personIds') ? Optional.present(IdsFilter.fromJson(json[r'personIds'])) : const Optional.absent(),
|
||||
rating: json.containsKey(r'rating') ? Optional.present(NumberFilterNullable.fromJson(json[r'rating'])) : const Optional.absent(),
|
||||
state: json.containsKey(r'state') ? Optional.present(StringFilterNullable.fromJson(json[r'state'])) : const Optional.absent(),
|
||||
tagIds: json.containsKey(r'tagIds') ? Optional.present(IdsFilter.fromJson(json[r'tagIds'])) : const Optional.absent(),
|
||||
takenAt: json.containsKey(r'takenAt') ? Optional.present(DateFilter.fromJson(json[r'takenAt'])) : const Optional.absent(),
|
||||
trashedAt: json.containsKey(r'trashedAt') ? Optional.present(DateFilterNullable.fromJson(json[r'trashedAt'])) : const Optional.absent(),
|
||||
type: json.containsKey(r'type') ? Optional.present(EnumFilterAssetType.fromJson(json[r'type'])) : const Optional.absent(),
|
||||
updatedAt: json.containsKey(r'updatedAt') ? Optional.present(DateFilter.fromJson(json[r'updatedAt'])) : const Optional.absent(),
|
||||
visibility: json.containsKey(r'visibility') ? Optional.present(EnumFilterAssetVisibility.fromJson(json[r'visibility'])) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<SearchFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <SearchFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = SearchFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, SearchFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, SearchFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = SearchFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of SearchFilter-objects as value to a dart map
|
||||
static Map<String, List<SearchFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<SearchFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = SearchFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+603
@@ -0,0 +1,603 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 SearchFilterBranch {
|
||||
/// Returns a new [SearchFilterBranch] instance.
|
||||
SearchFilterBranch({
|
||||
this.albumIds = const Optional.absent(),
|
||||
this.checksum = const Optional.absent(),
|
||||
this.city = const Optional.absent(),
|
||||
this.country = const Optional.absent(),
|
||||
this.createdAt = const Optional.absent(),
|
||||
this.description = const Optional.absent(),
|
||||
this.encodedVideoPath = const Optional.absent(),
|
||||
this.fileSizeInBytes = const Optional.absent(),
|
||||
this.hasAlbums = const Optional.absent(),
|
||||
this.hasPeople = const Optional.absent(),
|
||||
this.hasTags = const Optional.absent(),
|
||||
this.id = const Optional.absent(),
|
||||
this.isEncoded = const Optional.absent(),
|
||||
this.isFavorite = const Optional.absent(),
|
||||
this.isMotion = const Optional.absent(),
|
||||
this.isOffline = const Optional.absent(),
|
||||
this.lensModel = const Optional.absent(),
|
||||
this.libraryId = const Optional.absent(),
|
||||
this.make = const Optional.absent(),
|
||||
this.model = const Optional.absent(),
|
||||
this.ocr = const Optional.absent(),
|
||||
this.originalFileName = const Optional.absent(),
|
||||
this.originalPath = const Optional.absent(),
|
||||
this.personIds = const Optional.absent(),
|
||||
this.rating = const Optional.absent(),
|
||||
this.state = const Optional.absent(),
|
||||
this.tagIds = const Optional.absent(),
|
||||
this.takenAt = const Optional.absent(),
|
||||
this.trashedAt = const Optional.absent(),
|
||||
this.type = const Optional.absent(),
|
||||
this.updatedAt = const Optional.absent(),
|
||||
this.visibility = const Optional.absent(),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdsFilter?> albumIds;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilter?> checksum;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> city;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> country;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateFilter?> createdAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringPatternFilter?> description;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilter?> encodedVideoPath;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<NumberFilter?> fileSizeInBytes;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> hasAlbums;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> hasPeople;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> hasTags;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdFilter?> id;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> isEncoded;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> isFavorite;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> isMotion;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<BoolFilter?> isOffline;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> lensModel;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdFilterNullable?> libraryId;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> make;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> model;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringSimilarityFilter?> ocr;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringPatternFilter?> originalFileName;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringPatternFilter?> originalPath;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdsFilter?> personIds;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<NumberFilterNullable?> rating;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<StringFilterNullable?> state;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<IdsFilter?> tagIds;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateFilter?> takenAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateFilterNullable?> trashedAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<EnumFilterAssetType?> type;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<DateFilter?> updatedAt;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<EnumFilterAssetVisibility?> visibility;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SearchFilterBranch &&
|
||||
other.albumIds == albumIds &&
|
||||
other.checksum == checksum &&
|
||||
other.city == city &&
|
||||
other.country == country &&
|
||||
other.createdAt == createdAt &&
|
||||
other.description == description &&
|
||||
other.encodedVideoPath == encodedVideoPath &&
|
||||
other.fileSizeInBytes == fileSizeInBytes &&
|
||||
other.hasAlbums == hasAlbums &&
|
||||
other.hasPeople == hasPeople &&
|
||||
other.hasTags == hasTags &&
|
||||
other.id == id &&
|
||||
other.isEncoded == isEncoded &&
|
||||
other.isFavorite == isFavorite &&
|
||||
other.isMotion == isMotion &&
|
||||
other.isOffline == isOffline &&
|
||||
other.lensModel == lensModel &&
|
||||
other.libraryId == libraryId &&
|
||||
other.make == make &&
|
||||
other.model == model &&
|
||||
other.ocr == ocr &&
|
||||
other.originalFileName == originalFileName &&
|
||||
other.originalPath == originalPath &&
|
||||
other.personIds == personIds &&
|
||||
other.rating == rating &&
|
||||
other.state == state &&
|
||||
other.tagIds == tagIds &&
|
||||
other.takenAt == takenAt &&
|
||||
other.trashedAt == trashedAt &&
|
||||
other.type == type &&
|
||||
other.updatedAt == updatedAt &&
|
||||
other.visibility == visibility;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(albumIds == null ? 0 : albumIds!.hashCode) +
|
||||
(checksum == null ? 0 : checksum!.hashCode) +
|
||||
(city == null ? 0 : city!.hashCode) +
|
||||
(country == null ? 0 : country!.hashCode) +
|
||||
(createdAt == null ? 0 : createdAt!.hashCode) +
|
||||
(description == null ? 0 : description!.hashCode) +
|
||||
(encodedVideoPath == null ? 0 : encodedVideoPath!.hashCode) +
|
||||
(fileSizeInBytes == null ? 0 : fileSizeInBytes!.hashCode) +
|
||||
(hasAlbums == null ? 0 : hasAlbums!.hashCode) +
|
||||
(hasPeople == null ? 0 : hasPeople!.hashCode) +
|
||||
(hasTags == null ? 0 : hasTags!.hashCode) +
|
||||
(id == null ? 0 : id!.hashCode) +
|
||||
(isEncoded == null ? 0 : isEncoded!.hashCode) +
|
||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||
(isMotion == null ? 0 : isMotion!.hashCode) +
|
||||
(isOffline == null ? 0 : isOffline!.hashCode) +
|
||||
(lensModel == null ? 0 : lensModel!.hashCode) +
|
||||
(libraryId == null ? 0 : libraryId!.hashCode) +
|
||||
(make == null ? 0 : make!.hashCode) +
|
||||
(model == null ? 0 : model!.hashCode) +
|
||||
(ocr == null ? 0 : ocr!.hashCode) +
|
||||
(originalFileName == null ? 0 : originalFileName!.hashCode) +
|
||||
(originalPath == null ? 0 : originalPath!.hashCode) +
|
||||
(personIds == null ? 0 : personIds!.hashCode) +
|
||||
(rating == null ? 0 : rating!.hashCode) +
|
||||
(state == null ? 0 : state!.hashCode) +
|
||||
(tagIds == null ? 0 : tagIds!.hashCode) +
|
||||
(takenAt == null ? 0 : takenAt!.hashCode) +
|
||||
(trashedAt == null ? 0 : trashedAt!.hashCode) +
|
||||
(type == null ? 0 : type!.hashCode) +
|
||||
(updatedAt == null ? 0 : updatedAt!.hashCode) +
|
||||
(visibility == null ? 0 : visibility!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SearchFilterBranch[albumIds=$albumIds, checksum=$checksum, city=$city, country=$country, createdAt=$createdAt, description=$description, encodedVideoPath=$encodedVideoPath, fileSizeInBytes=$fileSizeInBytes, hasAlbums=$hasAlbums, hasPeople=$hasPeople, hasTags=$hasTags, id=$id, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isOffline=$isOffline, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, originalFileName=$originalFileName, originalPath=$originalPath, personIds=$personIds, rating=$rating, state=$state, tagIds=$tagIds, takenAt=$takenAt, trashedAt=$trashedAt, type=$type, updatedAt=$updatedAt, visibility=$visibility]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.albumIds.isPresent) {
|
||||
final value = this.albumIds.value;
|
||||
json[r'albumIds'] = value;
|
||||
}
|
||||
if (this.checksum.isPresent) {
|
||||
final value = this.checksum.value;
|
||||
json[r'checksum'] = value;
|
||||
}
|
||||
if (this.city.isPresent) {
|
||||
final value = this.city.value;
|
||||
json[r'city'] = value;
|
||||
}
|
||||
if (this.country.isPresent) {
|
||||
final value = this.country.value;
|
||||
json[r'country'] = value;
|
||||
}
|
||||
if (this.createdAt.isPresent) {
|
||||
final value = this.createdAt.value;
|
||||
json[r'createdAt'] = value;
|
||||
}
|
||||
if (this.description.isPresent) {
|
||||
final value = this.description.value;
|
||||
json[r'description'] = value;
|
||||
}
|
||||
if (this.encodedVideoPath.isPresent) {
|
||||
final value = this.encodedVideoPath.value;
|
||||
json[r'encodedVideoPath'] = value;
|
||||
}
|
||||
if (this.fileSizeInBytes.isPresent) {
|
||||
final value = this.fileSizeInBytes.value;
|
||||
json[r'fileSizeInBytes'] = value;
|
||||
}
|
||||
if (this.hasAlbums.isPresent) {
|
||||
final value = this.hasAlbums.value;
|
||||
json[r'hasAlbums'] = value;
|
||||
}
|
||||
if (this.hasPeople.isPresent) {
|
||||
final value = this.hasPeople.value;
|
||||
json[r'hasPeople'] = value;
|
||||
}
|
||||
if (this.hasTags.isPresent) {
|
||||
final value = this.hasTags.value;
|
||||
json[r'hasTags'] = value;
|
||||
}
|
||||
if (this.id.isPresent) {
|
||||
final value = this.id.value;
|
||||
json[r'id'] = value;
|
||||
}
|
||||
if (this.isEncoded.isPresent) {
|
||||
final value = this.isEncoded.value;
|
||||
json[r'isEncoded'] = value;
|
||||
}
|
||||
if (this.isFavorite.isPresent) {
|
||||
final value = this.isFavorite.value;
|
||||
json[r'isFavorite'] = value;
|
||||
}
|
||||
if (this.isMotion.isPresent) {
|
||||
final value = this.isMotion.value;
|
||||
json[r'isMotion'] = value;
|
||||
}
|
||||
if (this.isOffline.isPresent) {
|
||||
final value = this.isOffline.value;
|
||||
json[r'isOffline'] = value;
|
||||
}
|
||||
if (this.lensModel.isPresent) {
|
||||
final value = this.lensModel.value;
|
||||
json[r'lensModel'] = value;
|
||||
}
|
||||
if (this.libraryId.isPresent) {
|
||||
final value = this.libraryId.value;
|
||||
json[r'libraryId'] = value;
|
||||
}
|
||||
if (this.make.isPresent) {
|
||||
final value = this.make.value;
|
||||
json[r'make'] = value;
|
||||
}
|
||||
if (this.model.isPresent) {
|
||||
final value = this.model.value;
|
||||
json[r'model'] = value;
|
||||
}
|
||||
if (this.ocr.isPresent) {
|
||||
final value = this.ocr.value;
|
||||
json[r'ocr'] = value;
|
||||
}
|
||||
if (this.originalFileName.isPresent) {
|
||||
final value = this.originalFileName.value;
|
||||
json[r'originalFileName'] = value;
|
||||
}
|
||||
if (this.originalPath.isPresent) {
|
||||
final value = this.originalPath.value;
|
||||
json[r'originalPath'] = value;
|
||||
}
|
||||
if (this.personIds.isPresent) {
|
||||
final value = this.personIds.value;
|
||||
json[r'personIds'] = value;
|
||||
}
|
||||
if (this.rating.isPresent) {
|
||||
final value = this.rating.value;
|
||||
json[r'rating'] = value;
|
||||
}
|
||||
if (this.state.isPresent) {
|
||||
final value = this.state.value;
|
||||
json[r'state'] = value;
|
||||
}
|
||||
if (this.tagIds.isPresent) {
|
||||
final value = this.tagIds.value;
|
||||
json[r'tagIds'] = value;
|
||||
}
|
||||
if (this.takenAt.isPresent) {
|
||||
final value = this.takenAt.value;
|
||||
json[r'takenAt'] = value;
|
||||
}
|
||||
if (this.trashedAt.isPresent) {
|
||||
final value = this.trashedAt.value;
|
||||
json[r'trashedAt'] = value;
|
||||
}
|
||||
if (this.type.isPresent) {
|
||||
final value = this.type.value;
|
||||
json[r'type'] = value;
|
||||
}
|
||||
if (this.updatedAt.isPresent) {
|
||||
final value = this.updatedAt.value;
|
||||
json[r'updatedAt'] = value;
|
||||
}
|
||||
if (this.visibility.isPresent) {
|
||||
final value = this.visibility.value;
|
||||
json[r'visibility'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [SearchFilterBranch] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static SearchFilterBranch? fromJson(dynamic value) {
|
||||
upgradeDto(value, "SearchFilterBranch");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SearchFilterBranch(
|
||||
albumIds: json.containsKey(r'albumIds') ? Optional.present(IdsFilter.fromJson(json[r'albumIds'])) : const Optional.absent(),
|
||||
checksum: json.containsKey(r'checksum') ? Optional.present(StringFilter.fromJson(json[r'checksum'])) : const Optional.absent(),
|
||||
city: json.containsKey(r'city') ? Optional.present(StringFilterNullable.fromJson(json[r'city'])) : const Optional.absent(),
|
||||
country: json.containsKey(r'country') ? Optional.present(StringFilterNullable.fromJson(json[r'country'])) : const Optional.absent(),
|
||||
createdAt: json.containsKey(r'createdAt') ? Optional.present(DateFilter.fromJson(json[r'createdAt'])) : const Optional.absent(),
|
||||
description: json.containsKey(r'description') ? Optional.present(StringPatternFilter.fromJson(json[r'description'])) : const Optional.absent(),
|
||||
encodedVideoPath: json.containsKey(r'encodedVideoPath') ? Optional.present(StringFilter.fromJson(json[r'encodedVideoPath'])) : const Optional.absent(),
|
||||
fileSizeInBytes: json.containsKey(r'fileSizeInBytes') ? Optional.present(NumberFilter.fromJson(json[r'fileSizeInBytes'])) : const Optional.absent(),
|
||||
hasAlbums: json.containsKey(r'hasAlbums') ? Optional.present(BoolFilter.fromJson(json[r'hasAlbums'])) : const Optional.absent(),
|
||||
hasPeople: json.containsKey(r'hasPeople') ? Optional.present(BoolFilter.fromJson(json[r'hasPeople'])) : const Optional.absent(),
|
||||
hasTags: json.containsKey(r'hasTags') ? Optional.present(BoolFilter.fromJson(json[r'hasTags'])) : const Optional.absent(),
|
||||
id: json.containsKey(r'id') ? Optional.present(IdFilter.fromJson(json[r'id'])) : const Optional.absent(),
|
||||
isEncoded: json.containsKey(r'isEncoded') ? Optional.present(BoolFilter.fromJson(json[r'isEncoded'])) : const Optional.absent(),
|
||||
isFavorite: json.containsKey(r'isFavorite') ? Optional.present(BoolFilter.fromJson(json[r'isFavorite'])) : const Optional.absent(),
|
||||
isMotion: json.containsKey(r'isMotion') ? Optional.present(BoolFilter.fromJson(json[r'isMotion'])) : const Optional.absent(),
|
||||
isOffline: json.containsKey(r'isOffline') ? Optional.present(BoolFilter.fromJson(json[r'isOffline'])) : const Optional.absent(),
|
||||
lensModel: json.containsKey(r'lensModel') ? Optional.present(StringFilterNullable.fromJson(json[r'lensModel'])) : const Optional.absent(),
|
||||
libraryId: json.containsKey(r'libraryId') ? Optional.present(IdFilterNullable.fromJson(json[r'libraryId'])) : const Optional.absent(),
|
||||
make: json.containsKey(r'make') ? Optional.present(StringFilterNullable.fromJson(json[r'make'])) : const Optional.absent(),
|
||||
model: json.containsKey(r'model') ? Optional.present(StringFilterNullable.fromJson(json[r'model'])) : const Optional.absent(),
|
||||
ocr: json.containsKey(r'ocr') ? Optional.present(StringSimilarityFilter.fromJson(json[r'ocr'])) : const Optional.absent(),
|
||||
originalFileName: json.containsKey(r'originalFileName') ? Optional.present(StringPatternFilter.fromJson(json[r'originalFileName'])) : const Optional.absent(),
|
||||
originalPath: json.containsKey(r'originalPath') ? Optional.present(StringPatternFilter.fromJson(json[r'originalPath'])) : const Optional.absent(),
|
||||
personIds: json.containsKey(r'personIds') ? Optional.present(IdsFilter.fromJson(json[r'personIds'])) : const Optional.absent(),
|
||||
rating: json.containsKey(r'rating') ? Optional.present(NumberFilterNullable.fromJson(json[r'rating'])) : const Optional.absent(),
|
||||
state: json.containsKey(r'state') ? Optional.present(StringFilterNullable.fromJson(json[r'state'])) : const Optional.absent(),
|
||||
tagIds: json.containsKey(r'tagIds') ? Optional.present(IdsFilter.fromJson(json[r'tagIds'])) : const Optional.absent(),
|
||||
takenAt: json.containsKey(r'takenAt') ? Optional.present(DateFilter.fromJson(json[r'takenAt'])) : const Optional.absent(),
|
||||
trashedAt: json.containsKey(r'trashedAt') ? Optional.present(DateFilterNullable.fromJson(json[r'trashedAt'])) : const Optional.absent(),
|
||||
type: json.containsKey(r'type') ? Optional.present(EnumFilterAssetType.fromJson(json[r'type'])) : const Optional.absent(),
|
||||
updatedAt: json.containsKey(r'updatedAt') ? Optional.present(DateFilter.fromJson(json[r'updatedAt'])) : const Optional.absent(),
|
||||
visibility: json.containsKey(r'visibility') ? Optional.present(EnumFilterAssetVisibility.fromJson(json[r'visibility'])) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<SearchFilterBranch> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <SearchFilterBranch>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = SearchFilterBranch.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, SearchFilterBranch> mapFromJson(dynamic json) {
|
||||
final map = <String, SearchFilterBranch>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = SearchFilterBranch.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of SearchFilterBranch-objects as value to a dart map
|
||||
static Map<String, List<SearchFilterBranch>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<SearchFilterBranch>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = SearchFilterBranch.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+123
@@ -0,0 +1,123 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 SearchOrder {
|
||||
/// Returns a new [SearchOrder] instance.
|
||||
SearchOrder({
|
||||
this.direction = const Optional.absent(),
|
||||
this.field = const Optional.absent(),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<AssetOrder?> direction;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<SearchOrderField?> field;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is SearchOrder &&
|
||||
other.direction == direction &&
|
||||
other.field == field;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(direction == null ? 0 : direction!.hashCode) +
|
||||
(field == null ? 0 : field!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SearchOrder[direction=$direction, field=$field]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.direction.isPresent) {
|
||||
final value = this.direction.value;
|
||||
json[r'direction'] = value;
|
||||
}
|
||||
if (this.field.isPresent) {
|
||||
final value = this.field.value;
|
||||
json[r'field'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [SearchOrder] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static SearchOrder? fromJson(dynamic value) {
|
||||
upgradeDto(value, "SearchOrder");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return SearchOrder(
|
||||
direction: json.containsKey(r'direction') ? Optional.present(AssetOrder.fromJson(json[r'direction'])) : const Optional.absent(),
|
||||
field: json.containsKey(r'field') ? Optional.present(SearchOrderField.fromJson(json[r'field'])) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<SearchOrder> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <SearchOrder>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = SearchOrder.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, SearchOrder> mapFromJson(dynamic json) {
|
||||
final map = <String, SearchOrder>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = SearchOrder.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of SearchOrder-objects as value to a dart map
|
||||
static Map<String, List<SearchOrder>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<SearchOrder>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = SearchOrder.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+94
@@ -0,0 +1,94 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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;
|
||||
|
||||
|
||||
enum SearchOrderField {
|
||||
fileCreatedAt._(r'fileCreatedAt'),
|
||||
localDateTime._(r'localDateTime'),
|
||||
fileSizeInBytes._(r'fileSizeInBytes'),
|
||||
rating._(r'rating'),
|
||||
;
|
||||
|
||||
/// Instantiate a new enum with the provided value.
|
||||
const SearchOrderField._(this._value);
|
||||
|
||||
/// The underlying value of this enum member.
|
||||
final String _value;
|
||||
|
||||
@override
|
||||
String toString() => _value;
|
||||
|
||||
/// Encodes this enum as a value suitable for JSON.
|
||||
String toJson() => _value;
|
||||
|
||||
/// Returns the instance of [SearchOrderField] that was successfully decoded
|
||||
/// from the passed [value] on success, null otherwise.
|
||||
static SearchOrderField? fromJson(dynamic value) => SearchOrderFieldTypeTransformer().decode(value);
|
||||
|
||||
/// Returns a [List] containing instances of [SearchOrderField]
|
||||
/// that were successfully decoded from the passed [JSON][json].
|
||||
static List<SearchOrderField> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <SearchOrderField>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = SearchOrderField.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
}
|
||||
|
||||
/// Transformation class that can [encode] an instance of [SearchOrderField] to String,
|
||||
/// and [decode] dynamic data back to [SearchOrderField].
|
||||
class SearchOrderFieldTypeTransformer {
|
||||
factory SearchOrderFieldTypeTransformer() => _instance ??= const SearchOrderFieldTypeTransformer._();
|
||||
|
||||
const SearchOrderFieldTypeTransformer._();
|
||||
|
||||
/// Encodes this enum as a value suitable for JSON.
|
||||
String encode(SearchOrderField data) => data._value;
|
||||
|
||||
/// Returns the instance of [SearchOrderField] that was successfully decoded
|
||||
/// from the passed [data] value on success, null otherwise.
|
||||
///
|
||||
/// If [allowNull] is true and the [dynamic value][data] cannot be decoded successfully,
|
||||
/// then null is returned. However, if [allowNull] is false and the [dynamic value][data]
|
||||
/// cannot be decoded successfully, then an [UnimplementedError] is thrown.
|
||||
///
|
||||
/// The [allowNull] is very handy when an API changes and a new enum value is added or removed,
|
||||
/// and users are still using an old app with the old code.
|
||||
SearchOrderField? decode(dynamic data, {bool allowNull = true}) {
|
||||
if (data is SearchOrderField) {
|
||||
return data;
|
||||
}
|
||||
if (data != null) {
|
||||
switch (data) {
|
||||
case r'fileCreatedAt': return SearchOrderField.fileCreatedAt;
|
||||
case r'localDateTime': return SearchOrderField.localDateTime;
|
||||
case r'fileSizeInBytes': return SearchOrderField.fileSizeInBytes;
|
||||
case r'rating': return SearchOrderField.rating;
|
||||
default:
|
||||
if (!allowNull) {
|
||||
throw ArgumentError('Unknown enum value to decode: $data');
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// The singleton instance of this transformer.
|
||||
static SearchOrderFieldTypeTransformer? _instance;
|
||||
}
|
||||
|
||||
+34
-1
@@ -18,6 +18,8 @@ class SmartSearchDto {
|
||||
this.country = const Optional.absent(),
|
||||
this.createdAfter = const Optional.absent(),
|
||||
this.createdBefore = const Optional.absent(),
|
||||
this.cursor = const Optional.absent(),
|
||||
this.filter = const Optional.absent(),
|
||||
this.isEncoded = const Optional.absent(),
|
||||
this.isFavorite = const Optional.absent(),
|
||||
this.isMotion = const Optional.absent(),
|
||||
@@ -76,6 +78,23 @@ class SmartSearchDto {
|
||||
///
|
||||
Optional<DateTime?> createdBefore;
|
||||
|
||||
/// Cursor for the next page of results
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> cursor;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<SearchFilter?> filter;
|
||||
|
||||
/// Filter by encoded status
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
@@ -303,6 +322,8 @@ class SmartSearchDto {
|
||||
other.country == country &&
|
||||
other.createdAfter == createdAfter &&
|
||||
other.createdBefore == createdBefore &&
|
||||
other.cursor == cursor &&
|
||||
other.filter == filter &&
|
||||
other.isEncoded == isEncoded &&
|
||||
other.isFavorite == isFavorite &&
|
||||
other.isMotion == isMotion &&
|
||||
@@ -341,6 +362,8 @@ class SmartSearchDto {
|
||||
(country == null ? 0 : country!.hashCode) +
|
||||
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
||||
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
||||
(cursor == null ? 0 : cursor!.hashCode) +
|
||||
(filter == null ? 0 : filter!.hashCode) +
|
||||
(isEncoded == null ? 0 : isEncoded!.hashCode) +
|
||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||
(isMotion == null ? 0 : isMotion!.hashCode) +
|
||||
@@ -372,7 +395,7 @@ class SmartSearchDto {
|
||||
(withExif == null ? 0 : withExif!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'SmartSearchDto[albumIds=$albumIds, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, language=$language, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, page=$page, personIds=$personIds, query=$query, queryAssetId=$queryAssetId, rating=$rating, size=$size, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility, withDeleted=$withDeleted, withExif=$withExif]';
|
||||
String toString() => 'SmartSearchDto[albumIds=$albumIds, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, cursor=$cursor, filter=$filter, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, language=$language, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, page=$page, personIds=$personIds, query=$query, queryAssetId=$queryAssetId, rating=$rating, size=$size, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility, withDeleted=$withDeleted, withExif=$withExif]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -400,6 +423,14 @@ class SmartSearchDto {
|
||||
? value.millisecondsSinceEpoch
|
||||
: value.toUtc().toIso8601String());
|
||||
}
|
||||
if (this.cursor.isPresent) {
|
||||
final value = this.cursor.value;
|
||||
json[r'cursor'] = value;
|
||||
}
|
||||
if (this.filter.isPresent) {
|
||||
final value = this.filter.value;
|
||||
json[r'filter'] = value;
|
||||
}
|
||||
if (this.isEncoded.isPresent) {
|
||||
final value = this.isEncoded.value;
|
||||
json[r'isEncoded'] = value;
|
||||
@@ -547,6 +578,8 @@ class SmartSearchDto {
|
||||
country: json.containsKey(r'country') ? Optional.present(mapValueOfType<String>(json, r'country')) : const Optional.absent(),
|
||||
createdAfter: json.containsKey(r'createdAfter') ? Optional.present(mapDateTime(json, r'createdAfter', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
createdBefore: json.containsKey(r'createdBefore') ? Optional.present(mapDateTime(json, r'createdBefore', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
cursor: json.containsKey(r'cursor') ? Optional.present(mapValueOfType<String>(json, r'cursor')) : const Optional.absent(),
|
||||
filter: json.containsKey(r'filter') ? Optional.present(SearchFilter.fromJson(json[r'filter'])) : const Optional.absent(),
|
||||
isEncoded: json.containsKey(r'isEncoded') ? Optional.present(mapValueOfType<bool>(json, r'isEncoded')) : const Optional.absent(),
|
||||
isFavorite: json.containsKey(r'isFavorite') ? Optional.present(mapValueOfType<bool>(json, r'isFavorite')) : const Optional.absent(),
|
||||
isMotion: json.containsKey(r'isMotion') ? Optional.present(mapValueOfType<bool>(json, r'isMotion')) : const Optional.absent(),
|
||||
|
||||
+17
-1
@@ -19,6 +19,7 @@ class StatisticsSearchDto {
|
||||
this.createdAfter = const Optional.absent(),
|
||||
this.createdBefore = const Optional.absent(),
|
||||
this.description = const Optional.absent(),
|
||||
this.filter = const Optional.absent(),
|
||||
this.isEncoded = const Optional.absent(),
|
||||
this.isFavorite = const Optional.absent(),
|
||||
this.isMotion = const Optional.absent(),
|
||||
@@ -79,6 +80,14 @@ class StatisticsSearchDto {
|
||||
///
|
||||
Optional<String?> description;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<SearchFilter?> filter;
|
||||
|
||||
/// Filter by encoded status
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
@@ -238,6 +247,7 @@ class StatisticsSearchDto {
|
||||
other.createdAfter == createdAfter &&
|
||||
other.createdBefore == createdBefore &&
|
||||
other.description == description &&
|
||||
other.filter == filter &&
|
||||
other.isEncoded == isEncoded &&
|
||||
other.isFavorite == isFavorite &&
|
||||
other.isMotion == isMotion &&
|
||||
@@ -270,6 +280,7 @@ class StatisticsSearchDto {
|
||||
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
||||
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
||||
(description == null ? 0 : description!.hashCode) +
|
||||
(filter == null ? 0 : filter!.hashCode) +
|
||||
(isEncoded == null ? 0 : isEncoded!.hashCode) +
|
||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||
(isMotion == null ? 0 : isMotion!.hashCode) +
|
||||
@@ -294,7 +305,7 @@ class StatisticsSearchDto {
|
||||
(visibility == null ? 0 : visibility!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'StatisticsSearchDto[albumIds=$albumIds, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, description=$description, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, personIds=$personIds, rating=$rating, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility]';
|
||||
String toString() => 'StatisticsSearchDto[albumIds=$albumIds, city=$city, country=$country, createdAfter=$createdAfter, createdBefore=$createdBefore, description=$description, filter=$filter, isEncoded=$isEncoded, isFavorite=$isFavorite, isMotion=$isMotion, isNotInAlbum=$isNotInAlbum, isOffline=$isOffline, lensModel=$lensModel, libraryId=$libraryId, make=$make, model=$model, ocr=$ocr, personIds=$personIds, rating=$rating, state=$state, tagIds=$tagIds, takenAfter=$takenAfter, takenBefore=$takenBefore, trashedAfter=$trashedAfter, trashedBefore=$trashedBefore, type=$type, updatedAfter=$updatedAfter, updatedBefore=$updatedBefore, visibility=$visibility]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
@@ -326,6 +337,10 @@ class StatisticsSearchDto {
|
||||
final value = this.description.value;
|
||||
json[r'description'] = value;
|
||||
}
|
||||
if (this.filter.isPresent) {
|
||||
final value = this.filter.value;
|
||||
json[r'filter'] = value;
|
||||
}
|
||||
if (this.isEncoded.isPresent) {
|
||||
final value = this.isEncoded.value;
|
||||
json[r'isEncoded'] = value;
|
||||
@@ -446,6 +461,7 @@ class StatisticsSearchDto {
|
||||
createdAfter: json.containsKey(r'createdAfter') ? Optional.present(mapDateTime(json, r'createdAfter', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
createdBefore: json.containsKey(r'createdBefore') ? Optional.present(mapDateTime(json, r'createdBefore', r'/^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$/')) : const Optional.absent(),
|
||||
description: json.containsKey(r'description') ? Optional.present(mapValueOfType<String>(json, r'description')) : const Optional.absent(),
|
||||
filter: json.containsKey(r'filter') ? Optional.present(SearchFilter.fromJson(json[r'filter'])) : const Optional.absent(),
|
||||
isEncoded: json.containsKey(r'isEncoded') ? Optional.present(mapValueOfType<bool>(json, r'isEncoded')) : const Optional.absent(),
|
||||
isFavorite: json.containsKey(r'isFavorite') ? Optional.present(mapValueOfType<bool>(json, r'isFavorite')) : const Optional.absent(),
|
||||
isMotion: json.containsKey(r'isMotion') ? Optional.present(mapValueOfType<bool>(json, r'isMotion')) : const Optional.absent(),
|
||||
|
||||
+147
@@ -0,0 +1,147 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 StringFilter {
|
||||
/// Returns a new [StringFilter] instance.
|
||||
StringFilter({
|
||||
this.eq = const Optional.absent(),
|
||||
this.in_ = const Optional.present(const []),
|
||||
this.ne = const Optional.absent(),
|
||||
this.notIn = const Optional.present(const []),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> eq;
|
||||
|
||||
Optional<List<String>?> in_;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> ne;
|
||||
|
||||
Optional<List<String>?> notIn;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is StringFilter &&
|
||||
other.eq == eq &&
|
||||
_deepEquality.equals(other.in_, in_) &&
|
||||
other.ne == ne &&
|
||||
_deepEquality.equals(other.notIn, notIn);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(in_.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode) +
|
||||
(notIn.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'StringFilter[eq=$eq, in_=$in_, ne=$ne, notIn=$notIn]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.in_.isPresent) {
|
||||
final value = this.in_.value;
|
||||
json[r'in'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
if (this.notIn.isPresent) {
|
||||
final value = this.notIn.value;
|
||||
json[r'notIn'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [StringFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static StringFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "StringFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return StringFilter(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(mapValueOfType<String>(json, r'eq')) : const Optional.absent(),
|
||||
in_: json.containsKey(r'in') ? Optional.present(json[r'in'] is Iterable
|
||||
? (json[r'in'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(mapValueOfType<String>(json, r'ne')) : const Optional.absent(),
|
||||
notIn: json.containsKey(r'notIn') ? Optional.present(json[r'notIn'] is Iterable
|
||||
? (json[r'notIn'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<StringFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <StringFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = StringFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, StringFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, StringFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = StringFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of StringFilter-objects as value to a dart map
|
||||
static Map<String, List<StringFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<StringFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = StringFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+135
@@ -0,0 +1,135 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 StringFilterNullable {
|
||||
/// Returns a new [StringFilterNullable] instance.
|
||||
StringFilterNullable({
|
||||
this.eq = const Optional.absent(),
|
||||
this.in_ = const Optional.present(const []),
|
||||
this.ne = const Optional.absent(),
|
||||
this.notIn = const Optional.present(const []),
|
||||
});
|
||||
|
||||
Optional<String?> eq;
|
||||
|
||||
Optional<List<String>?> in_;
|
||||
|
||||
Optional<String?> ne;
|
||||
|
||||
Optional<List<String>?> notIn;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is StringFilterNullable &&
|
||||
other.eq == eq &&
|
||||
_deepEquality.equals(other.in_, in_) &&
|
||||
other.ne == ne &&
|
||||
_deepEquality.equals(other.notIn, notIn);
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(in_.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode) +
|
||||
(notIn.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'StringFilterNullable[eq=$eq, in_=$in_, ne=$ne, notIn=$notIn]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.in_.isPresent) {
|
||||
final value = this.in_.value;
|
||||
json[r'in'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
if (this.notIn.isPresent) {
|
||||
final value = this.notIn.value;
|
||||
json[r'notIn'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [StringFilterNullable] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static StringFilterNullable? fromJson(dynamic value) {
|
||||
upgradeDto(value, "StringFilterNullable");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return StringFilterNullable(
|
||||
eq: json.containsKey(r'eq') ? Optional.present(mapValueOfType<String>(json, r'eq')) : const Optional.absent(),
|
||||
in_: json.containsKey(r'in') ? Optional.present(json[r'in'] is Iterable
|
||||
? (json[r'in'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(mapValueOfType<String>(json, r'ne')) : const Optional.absent(),
|
||||
notIn: json.containsKey(r'notIn') ? Optional.present(json[r'notIn'] is Iterable
|
||||
? (json[r'notIn'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<StringFilterNullable> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <StringFilterNullable>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = StringFilterNullable.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, StringFilterNullable> mapFromJson(dynamic json) {
|
||||
final map = <String, StringFilterNullable>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = StringFilterNullable.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of StringFilterNullable-objects as value to a dart map
|
||||
static Map<String, List<StringFilterNullable>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<StringFilterNullable>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = StringFilterNullable.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
+199
@@ -0,0 +1,199 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 StringPatternFilter {
|
||||
/// Returns a new [StringPatternFilter] instance.
|
||||
StringPatternFilter({
|
||||
this.endsWith = const Optional.absent(),
|
||||
this.eq = const Optional.absent(),
|
||||
this.in_ = const Optional.present(const []),
|
||||
this.like = const Optional.absent(),
|
||||
this.ne = const Optional.absent(),
|
||||
this.notIn = const Optional.present(const []),
|
||||
this.notLike = const Optional.absent(),
|
||||
this.startsWith = const Optional.absent(),
|
||||
});
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> endsWith;
|
||||
|
||||
Optional<String?> eq;
|
||||
|
||||
Optional<List<String>?> in_;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> like;
|
||||
|
||||
Optional<String?> ne;
|
||||
|
||||
Optional<List<String>?> notIn;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> notLike;
|
||||
|
||||
///
|
||||
/// Please note: This property should have been non-nullable! Since the specification file
|
||||
/// does not include a default value (using the "default:" property), however, the generated
|
||||
/// source code must fall back to having a nullable type.
|
||||
/// Consider adding a "default:" property in the specification file to hide this note.
|
||||
///
|
||||
Optional<String?> startsWith;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is StringPatternFilter &&
|
||||
other.endsWith == endsWith &&
|
||||
other.eq == eq &&
|
||||
_deepEquality.equals(other.in_, in_) &&
|
||||
other.like == like &&
|
||||
other.ne == ne &&
|
||||
_deepEquality.equals(other.notIn, notIn) &&
|
||||
other.notLike == notLike &&
|
||||
other.startsWith == startsWith;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(endsWith == null ? 0 : endsWith!.hashCode) +
|
||||
(eq == null ? 0 : eq!.hashCode) +
|
||||
(in_.hashCode) +
|
||||
(like == null ? 0 : like!.hashCode) +
|
||||
(ne == null ? 0 : ne!.hashCode) +
|
||||
(notIn.hashCode) +
|
||||
(notLike == null ? 0 : notLike!.hashCode) +
|
||||
(startsWith == null ? 0 : startsWith!.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'StringPatternFilter[endsWith=$endsWith, eq=$eq, in_=$in_, like=$like, ne=$ne, notIn=$notIn, notLike=$notLike, startsWith=$startsWith]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
if (this.endsWith.isPresent) {
|
||||
final value = this.endsWith.value;
|
||||
json[r'endsWith'] = value;
|
||||
}
|
||||
if (this.eq.isPresent) {
|
||||
final value = this.eq.value;
|
||||
json[r'eq'] = value;
|
||||
}
|
||||
if (this.in_.isPresent) {
|
||||
final value = this.in_.value;
|
||||
json[r'in'] = value;
|
||||
}
|
||||
if (this.like.isPresent) {
|
||||
final value = this.like.value;
|
||||
json[r'like'] = value;
|
||||
}
|
||||
if (this.ne.isPresent) {
|
||||
final value = this.ne.value;
|
||||
json[r'ne'] = value;
|
||||
}
|
||||
if (this.notIn.isPresent) {
|
||||
final value = this.notIn.value;
|
||||
json[r'notIn'] = value;
|
||||
}
|
||||
if (this.notLike.isPresent) {
|
||||
final value = this.notLike.value;
|
||||
json[r'notLike'] = value;
|
||||
}
|
||||
if (this.startsWith.isPresent) {
|
||||
final value = this.startsWith.value;
|
||||
json[r'startsWith'] = value;
|
||||
}
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [StringPatternFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static StringPatternFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "StringPatternFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return StringPatternFilter(
|
||||
endsWith: json.containsKey(r'endsWith') ? Optional.present(mapValueOfType<String>(json, r'endsWith')) : const Optional.absent(),
|
||||
eq: json.containsKey(r'eq') ? Optional.present(mapValueOfType<String>(json, r'eq')) : const Optional.absent(),
|
||||
in_: json.containsKey(r'in') ? Optional.present(json[r'in'] is Iterable
|
||||
? (json[r'in'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
like: json.containsKey(r'like') ? Optional.present(mapValueOfType<String>(json, r'like')) : const Optional.absent(),
|
||||
ne: json.containsKey(r'ne') ? Optional.present(mapValueOfType<String>(json, r'ne')) : const Optional.absent(),
|
||||
notIn: json.containsKey(r'notIn') ? Optional.present(json[r'notIn'] is Iterable
|
||||
? (json[r'notIn'] as Iterable).cast<String>().toList(growable: false)
|
||||
: const []) : const Optional.absent(),
|
||||
notLike: json.containsKey(r'notLike') ? Optional.present(mapValueOfType<String>(json, r'notLike')) : const Optional.absent(),
|
||||
startsWith: json.containsKey(r'startsWith') ? Optional.present(mapValueOfType<String>(json, r'startsWith')) : const Optional.absent(),
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<StringPatternFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <StringPatternFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = StringPatternFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, StringPatternFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, StringPatternFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = StringPatternFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of StringPatternFilter-objects as value to a dart map
|
||||
static Map<String, List<StringPatternFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<StringPatternFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = StringPatternFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,99 @@
|
||||
//
|
||||
// AUTO-GENERATED FILE, DO NOT MODIFY!
|
||||
//
|
||||
// @dart=2.18
|
||||
|
||||
// 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 StringSimilarityFilter {
|
||||
/// Returns a new [StringSimilarityFilter] instance.
|
||||
StringSimilarityFilter({
|
||||
required this.matches,
|
||||
});
|
||||
|
||||
String matches;
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) => identical(this, other) || other is StringSimilarityFilter &&
|
||||
other.matches == matches;
|
||||
|
||||
@override
|
||||
int get hashCode =>
|
||||
// ignore: unnecessary_parenthesis
|
||||
(matches.hashCode);
|
||||
|
||||
@override
|
||||
String toString() => 'StringSimilarityFilter[matches=$matches]';
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final json = <String, dynamic>{};
|
||||
json[r'matches'] = this.matches;
|
||||
return json;
|
||||
}
|
||||
|
||||
/// Returns a new [StringSimilarityFilter] instance and imports its values from
|
||||
/// [value] if it's a [Map], null otherwise.
|
||||
// ignore: prefer_constructors_over_static_methods
|
||||
static StringSimilarityFilter? fromJson(dynamic value) {
|
||||
upgradeDto(value, "StringSimilarityFilter");
|
||||
if (value is Map) {
|
||||
final json = value.cast<String, dynamic>();
|
||||
|
||||
return StringSimilarityFilter(
|
||||
matches: mapValueOfType<String>(json, r'matches')!,
|
||||
);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
static List<StringSimilarityFilter> listFromJson(dynamic json, {bool growable = false,}) {
|
||||
final result = <StringSimilarityFilter>[];
|
||||
if (json is List && json.isNotEmpty) {
|
||||
for (final row in json) {
|
||||
final value = StringSimilarityFilter.fromJson(row);
|
||||
if (value != null) {
|
||||
result.add(value);
|
||||
}
|
||||
}
|
||||
}
|
||||
return result.toList(growable: growable);
|
||||
}
|
||||
|
||||
static Map<String, StringSimilarityFilter> mapFromJson(dynamic json) {
|
||||
final map = <String, StringSimilarityFilter>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
json = json.cast<String, dynamic>(); // ignore: parameter_assignments
|
||||
for (final entry in json.entries) {
|
||||
final value = StringSimilarityFilter.fromJson(entry.value);
|
||||
if (value != null) {
|
||||
map[entry.key] = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
// maps a json object with a list of StringSimilarityFilter-objects as value to a dart map
|
||||
static Map<String, List<StringSimilarityFilter>> mapListFromJson(dynamic json, {bool growable = false,}) {
|
||||
final map = <String, List<StringSimilarityFilter>>{};
|
||||
if (json is Map && json.isNotEmpty) {
|
||||
// ignore: parameter_assignments
|
||||
json = json.cast<String, dynamic>();
|
||||
for (final entry in json.entries) {
|
||||
map[entry.key] = StringSimilarityFilter.listFromJson(entry.value, growable: growable,);
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
|
||||
/// The list of required keys that must be present in a JSON.
|
||||
static const requiredKeys = <String>{
|
||||
'matches',
|
||||
};
|
||||
}
|
||||
|
||||
+3213
-128
File diff suppressed because it is too large
Load Diff
@@ -1617,6 +1617,168 @@ export type SearchExploreResponseDto = {
|
||||
fieldName: string;
|
||||
items: SearchExploreItem[];
|
||||
};
|
||||
export type IdsFilter = {
|
||||
all?: string[];
|
||||
"any"?: string[];
|
||||
none?: string[];
|
||||
};
|
||||
export type StringFilter = {
|
||||
eq?: string;
|
||||
"in"?: string[];
|
||||
ne?: string;
|
||||
notIn?: string[];
|
||||
};
|
||||
export type StringFilterNullable = {
|
||||
eq?: string | null;
|
||||
"in"?: string[];
|
||||
ne?: string | null;
|
||||
notIn?: string[];
|
||||
};
|
||||
export type DateFilter = {
|
||||
eq?: string;
|
||||
gt?: string;
|
||||
gte?: string;
|
||||
lt?: string;
|
||||
lte?: string;
|
||||
ne?: string;
|
||||
};
|
||||
export type StringPatternFilter = {
|
||||
endsWith?: string;
|
||||
eq?: string | null;
|
||||
"in"?: string[];
|
||||
like?: string;
|
||||
ne?: string | null;
|
||||
notIn?: string[];
|
||||
notLike?: string;
|
||||
startsWith?: string;
|
||||
};
|
||||
export type NumberFilter = {
|
||||
eq?: number;
|
||||
gt?: number;
|
||||
gte?: number;
|
||||
"in"?: number[];
|
||||
lt?: number;
|
||||
lte?: number;
|
||||
ne?: number;
|
||||
notIn?: number[];
|
||||
};
|
||||
export type BoolFilter = {
|
||||
eq: boolean;
|
||||
};
|
||||
export type IdFilter = {
|
||||
eq?: string;
|
||||
ne?: string;
|
||||
};
|
||||
export type IdFilterNullable = {
|
||||
eq?: string | null;
|
||||
ne?: string | null;
|
||||
};
|
||||
export type StringSimilarityFilter = {
|
||||
matches: string;
|
||||
};
|
||||
export type NumberFilterNullable = {
|
||||
eq?: number | null;
|
||||
gt?: number;
|
||||
gte?: number;
|
||||
"in"?: number[];
|
||||
lt?: number;
|
||||
lte?: number;
|
||||
ne?: number | null;
|
||||
notIn?: number[];
|
||||
};
|
||||
export type DateFilterNullable = {
|
||||
eq?: string | null;
|
||||
gt?: string;
|
||||
gte?: string;
|
||||
lt?: string;
|
||||
lte?: string;
|
||||
ne?: string | null;
|
||||
};
|
||||
export type EnumFilterAssetType = {
|
||||
eq?: AssetTypeEnum;
|
||||
"in"?: AssetTypeEnum[];
|
||||
ne?: AssetTypeEnum;
|
||||
notIn?: AssetTypeEnum[];
|
||||
};
|
||||
export type EnumFilterAssetVisibility = {
|
||||
eq?: AssetVisibility;
|
||||
"in"?: AssetVisibility[];
|
||||
ne?: AssetVisibility;
|
||||
notIn?: AssetVisibility[];
|
||||
};
|
||||
export type SearchFilterBranch = {
|
||||
albumIds?: IdsFilter;
|
||||
checksum?: StringFilter;
|
||||
city?: StringFilterNullable;
|
||||
country?: StringFilterNullable;
|
||||
createdAt?: DateFilter;
|
||||
description?: StringPatternFilter;
|
||||
encodedVideoPath?: StringFilter;
|
||||
fileSizeInBytes?: NumberFilter;
|
||||
hasAlbums?: BoolFilter;
|
||||
hasPeople?: BoolFilter;
|
||||
hasTags?: BoolFilter;
|
||||
id?: IdFilter;
|
||||
isEncoded?: BoolFilter;
|
||||
isFavorite?: BoolFilter;
|
||||
isMotion?: BoolFilter;
|
||||
isOffline?: BoolFilter;
|
||||
lensModel?: StringFilterNullable;
|
||||
libraryId?: IdFilterNullable;
|
||||
make?: StringFilterNullable;
|
||||
model?: StringFilterNullable;
|
||||
ocr?: StringSimilarityFilter;
|
||||
originalFileName?: StringPatternFilter;
|
||||
originalPath?: StringPatternFilter;
|
||||
personIds?: IdsFilter;
|
||||
rating?: NumberFilterNullable;
|
||||
state?: StringFilterNullable;
|
||||
tagIds?: IdsFilter;
|
||||
takenAt?: DateFilter;
|
||||
trashedAt?: DateFilterNullable;
|
||||
"type"?: EnumFilterAssetType;
|
||||
updatedAt?: DateFilter;
|
||||
visibility?: EnumFilterAssetVisibility;
|
||||
};
|
||||
export type SearchFilter = {
|
||||
albumIds?: IdsFilter;
|
||||
checksum?: StringFilter;
|
||||
city?: StringFilterNullable;
|
||||
country?: StringFilterNullable;
|
||||
createdAt?: DateFilter;
|
||||
description?: StringPatternFilter;
|
||||
encodedVideoPath?: StringFilter;
|
||||
fileSizeInBytes?: NumberFilter;
|
||||
hasAlbums?: BoolFilter;
|
||||
hasPeople?: BoolFilter;
|
||||
hasTags?: BoolFilter;
|
||||
id?: IdFilter;
|
||||
isEncoded?: BoolFilter;
|
||||
isFavorite?: BoolFilter;
|
||||
isMotion?: BoolFilter;
|
||||
isOffline?: BoolFilter;
|
||||
lensModel?: StringFilterNullable;
|
||||
libraryId?: IdFilterNullable;
|
||||
make?: StringFilterNullable;
|
||||
model?: StringFilterNullable;
|
||||
ocr?: StringSimilarityFilter;
|
||||
or?: SearchFilterBranch[];
|
||||
originalFileName?: StringPatternFilter;
|
||||
originalPath?: StringPatternFilter;
|
||||
personIds?: IdsFilter;
|
||||
rating?: NumberFilterNullable;
|
||||
state?: StringFilterNullable;
|
||||
tagIds?: IdsFilter;
|
||||
takenAt?: DateFilter;
|
||||
trashedAt?: DateFilterNullable;
|
||||
"type"?: EnumFilterAssetType;
|
||||
updatedAt?: DateFilter;
|
||||
visibility?: EnumFilterAssetVisibility;
|
||||
};
|
||||
export type SearchOrder = {
|
||||
direction?: AssetOrder;
|
||||
field?: SearchOrderField;
|
||||
};
|
||||
export type MetadataSearchDto = {
|
||||
/** Filter by album IDs */
|
||||
albumIds?: string[];
|
||||
@@ -1630,10 +1792,13 @@ export type MetadataSearchDto = {
|
||||
createdAfter?: string;
|
||||
/** Filter by creation date (before) */
|
||||
createdBefore?: string;
|
||||
/** Cursor for the next page of results */
|
||||
cursor?: string;
|
||||
/** Filter by description text */
|
||||
description?: string;
|
||||
/** Filter by encoded video file path */
|
||||
encodedVideoPath?: string;
|
||||
filter?: SearchFilter;
|
||||
/** Filter by asset ID */
|
||||
id?: string;
|
||||
/** Filter by encoded status */
|
||||
@@ -1658,6 +1823,7 @@ export type MetadataSearchDto = {
|
||||
ocr?: string;
|
||||
/** Sort order */
|
||||
order?: AssetOrder;
|
||||
orderBy?: SearchOrder;
|
||||
/** Filter by original file name */
|
||||
originalFileName?: string;
|
||||
/** Filter by original file path */
|
||||
@@ -1725,6 +1891,8 @@ export type SearchAssetResponseDto = {
|
||||
count: number;
|
||||
facets: SearchFacetResponseDto[];
|
||||
items: AssetResponseDto[];
|
||||
/** Cursor for the next page of results */
|
||||
nextCursor: string | null;
|
||||
/** Next page token */
|
||||
nextPage: string | null;
|
||||
/** Total number of matching assets */
|
||||
@@ -1757,6 +1925,7 @@ export type RandomSearchDto = {
|
||||
createdAfter?: string;
|
||||
/** Filter by creation date (before) */
|
||||
createdBefore?: string;
|
||||
filter?: SearchFilter;
|
||||
/** Filter by encoded status */
|
||||
isEncoded?: boolean;
|
||||
/** Filter by favorite status */
|
||||
@@ -1821,6 +1990,9 @@ export type SmartSearchDto = {
|
||||
createdAfter?: string;
|
||||
/** Filter by creation date (before) */
|
||||
createdBefore?: string;
|
||||
/** Cursor for the next page of results */
|
||||
cursor?: string;
|
||||
filter?: SearchFilter;
|
||||
/** Filter by encoded status */
|
||||
isEncoded?: boolean;
|
||||
/** Filter by favorite status */
|
||||
@@ -1891,6 +2063,7 @@ export type StatisticsSearchDto = {
|
||||
createdBefore?: string;
|
||||
/** Filter by description text */
|
||||
description?: string;
|
||||
filter?: SearchFilter;
|
||||
/** Filter by encoded status */
|
||||
isEncoded?: boolean;
|
||||
/** Filter by favorite status */
|
||||
@@ -7501,6 +7674,12 @@ export enum JobName {
|
||||
IntegrityDeleteReportType = "IntegrityDeleteReportType",
|
||||
IntegrityDeleteReports = "IntegrityDeleteReports"
|
||||
}
|
||||
export enum SearchOrderField {
|
||||
FileCreatedAt = "fileCreatedAt",
|
||||
LocalDateTime = "localDateTime",
|
||||
FileSizeInBytes = "fileSizeInBytes",
|
||||
Rating = "rating"
|
||||
}
|
||||
export enum SearchSuggestionType {
|
||||
Country = "country",
|
||||
State = "state",
|
||||
|
||||
Reference in New Issue
Block a user