mirror of
https://github.com/immich-app/immich.git
synced 2025-05-24 01:12:58 -04:00
fix gen code
This commit is contained in:
parent
e475653206
commit
ac70d03693
@ -163,10 +163,11 @@ class Album {
|
|||||||
dto.order == AssetOrder.asc ? SortOrder.asc : SortOrder.desc;
|
dto.order == AssetOrder.asc ? SortOrder.asc : SortOrder.desc;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (dto.albumThumbnailAssetId.unwrapOrNull() != null) {
|
if (dto.albumThumbnailAssetId != null &&
|
||||||
|
dto.albumThumbnailAssetId!.isSome) {
|
||||||
a.thumbnail.value = await db.assets
|
a.thumbnail.value = await db.assets
|
||||||
.where()
|
.where()
|
||||||
.remoteIdEqualTo(dto.albumThumbnailAssetId.unwrap())
|
.remoteIdEqualTo(dto.albumThumbnailAssetId!.unwrap())
|
||||||
.findFirst();
|
.findFirst();
|
||||||
}
|
}
|
||||||
if (dto.albumUsers.isNotEmpty) {
|
if (dto.albumUsers.isNotEmpty) {
|
||||||
|
@ -27,9 +27,9 @@ class Asset {
|
|||||||
durationInSeconds = remote.duration.toDuration()?.inSeconds ?? 0,
|
durationInSeconds = remote.duration.toDuration()?.inSeconds ?? 0,
|
||||||
type = remote.type.toAssetType(),
|
type = remote.type.toAssetType(),
|
||||||
fileName = remote.originalFileName,
|
fileName = remote.originalFileName,
|
||||||
height = remote.exifInfo?.exifImageHeight.unwrapOrNull()?.toInt(),
|
height = remote.exifInfo?.exifImageHeight?.unwrapOrNull()?.toInt(),
|
||||||
width = remote.exifInfo?.exifImageWidth.unwrapOrNull()?.toInt(),
|
width = remote.exifInfo?.exifImageWidth?.unwrapOrNull()?.toInt(),
|
||||||
livePhotoVideoId = remote.livePhotoVideoId.unwrapOrNull(),
|
livePhotoVideoId = remote.livePhotoVideoId?.unwrapOrNull(),
|
||||||
ownerId = fastHash(remote.ownerId),
|
ownerId = fastHash(remote.ownerId),
|
||||||
exifInfo = remote.exifInfo == null
|
exifInfo = remote.exifInfo == null
|
||||||
? null
|
? null
|
||||||
@ -41,12 +41,12 @@ class Asset {
|
|||||||
// workaround to nullify stackPrimaryAssetId for the parent asset until we refactor the mobile app
|
// workaround to nullify stackPrimaryAssetId for the parent asset until we refactor the mobile app
|
||||||
// stack handling to properly handle it
|
// stack handling to properly handle it
|
||||||
stackPrimaryAssetId =
|
stackPrimaryAssetId =
|
||||||
remote.stack.unwrapOrNull()?.primaryAssetId == remote.id
|
remote.stack?.unwrapOrNull()?.primaryAssetId == remote.id
|
||||||
? null
|
? null
|
||||||
: remote.stack.unwrapOrNull()?.primaryAssetId,
|
: remote.stack?.unwrapOrNull()?.primaryAssetId,
|
||||||
stackCount = remote.stack.unwrapOrNull()?.assetCount ?? 0,
|
stackCount = remote.stack?.unwrapOrNull()?.assetCount ?? 0,
|
||||||
stackId = remote.stack.unwrapOrNull()?.id,
|
stackId = remote.stack?.unwrapOrNull()?.id,
|
||||||
thumbhash = remote.thumbhash.unwrapOrNull();
|
thumbhash = remote.thumbhash?.unwrapOrNull();
|
||||||
|
|
||||||
Asset({
|
Asset({
|
||||||
this.id = Isar.autoIncrement,
|
this.id = Isar.autoIncrement,
|
||||||
|
@ -5,24 +5,24 @@ import 'package:openapi/api.dart';
|
|||||||
abstract final class ExifDtoConverter {
|
abstract final class ExifDtoConverter {
|
||||||
static ExifInfo fromDto(ExifResponseDto dto) {
|
static ExifInfo fromDto(ExifResponseDto dto) {
|
||||||
return ExifInfo(
|
return ExifInfo(
|
||||||
fileSize: dto.fileSizeInByte.unwrapOrNull(),
|
fileSize: dto.fileSizeInByte?.unwrapOrNull(),
|
||||||
description: dto.description.unwrapOrNull(),
|
description: dto.description?.unwrapOrNull(),
|
||||||
orientation: dto.orientation.unwrapOrNull(),
|
orientation: dto.orientation?.unwrapOrNull(),
|
||||||
timeZone: dto.timeZone.unwrapOrNull(),
|
timeZone: dto.timeZone?.unwrapOrNull(),
|
||||||
dateTimeOriginal: dto.dateTimeOriginal.unwrapOrNull(),
|
dateTimeOriginal: dto.dateTimeOriginal?.unwrapOrNull(),
|
||||||
isFlipped: isOrientationFlipped(dto.orientation.unwrapOrNull()),
|
isFlipped: isOrientationFlipped(dto.orientation?.unwrapOrNull()),
|
||||||
latitude: dto.latitude.unwrapOrNull()?.toDouble(),
|
latitude: dto.latitude?.unwrapOrNull()?.toDouble(),
|
||||||
longitude: dto.longitude.unwrapOrNull()?.toDouble(),
|
longitude: dto.longitude?.unwrapOrNull()?.toDouble(),
|
||||||
city: dto.city.unwrapOrNull(),
|
city: dto.city?.unwrapOrNull(),
|
||||||
state: dto.state.unwrapOrNull(),
|
state: dto.state?.unwrapOrNull(),
|
||||||
country: dto.country.unwrapOrNull(),
|
country: dto.country?.unwrapOrNull(),
|
||||||
make: dto.make.unwrapOrNull(),
|
make: dto.make?.unwrapOrNull(),
|
||||||
model: dto.model.unwrapOrNull(),
|
model: dto.model?.unwrapOrNull(),
|
||||||
lens: dto.lensModel.unwrapOrNull(),
|
lens: dto.lensModel?.unwrapOrNull(),
|
||||||
f: dto.fNumber.unwrapOrNull()?.toDouble(),
|
f: dto.fNumber?.unwrapOrNull()?.toDouble(),
|
||||||
mm: dto.focalLength.unwrapOrNull()?.toDouble(),
|
mm: dto.focalLength?.unwrapOrNull()?.toDouble(),
|
||||||
iso: dto.iso.unwrapOrNull()?.toInt(),
|
iso: dto.iso?.unwrapOrNull()?.toInt(),
|
||||||
exposureSeconds: _exposureTimeToSeconds(dto.exposureTime.unwrapOrNull()),
|
exposureSeconds: _exposureTimeToSeconds(dto.exposureTime?.unwrapOrNull()),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -31,8 +31,8 @@ abstract final class UserConverter {
|
|||||||
inTimeline: false,
|
inTimeline: false,
|
||||||
isPartnerSharedBy: false,
|
isPartnerSharedBy: false,
|
||||||
isPartnerSharedWith: false,
|
isPartnerSharedWith: false,
|
||||||
quotaUsageInBytes: adminDto.quotaUsageInBytes.unwrapOrNull() ?? 0,
|
quotaUsageInBytes: adminDto.quotaUsageInBytes?.unwrapOrNull() ?? 0,
|
||||||
quotaSizeInBytes: adminDto.quotaSizeInBytes.unwrapOrNull() ?? 0,
|
quotaSizeInBytes: adminDto.quotaSizeInBytes?.unwrapOrNull() ?? 0,
|
||||||
);
|
);
|
||||||
|
|
||||||
static UserDto fromPartnerDto(PartnerResponseDto dto) => UserDto(
|
static UserDto fromPartnerDto(PartnerResponseDto dto) => UserDto(
|
||||||
|
@ -61,9 +61,9 @@ class SharedLink {
|
|||||||
: id = dto.id,
|
: id = dto.id,
|
||||||
allowDownload = dto.allowDownload,
|
allowDownload = dto.allowDownload,
|
||||||
allowUpload = dto.allowUpload,
|
allowUpload = dto.allowUpload,
|
||||||
description = dto.description.unwrapOrNull(),
|
description = dto.description?.unwrapOrNull(),
|
||||||
password = dto.password.unwrapOrNull(),
|
password = dto.password?.unwrapOrNull(),
|
||||||
expiresAt = dto.expiresAt.unwrapOrNull(),
|
expiresAt = dto.expiresAt?.unwrapOrNull(),
|
||||||
key = dto.key,
|
key = dto.key,
|
||||||
showMetadata = dto.showMetadata,
|
showMetadata = dto.showMetadata,
|
||||||
type = dto.type == SharedLinkType.ALBUM
|
type = dto.type == SharedLinkType.ALBUM
|
||||||
@ -73,7 +73,7 @@ class SharedLink {
|
|||||||
? dto.album?.albumName.toUpperCase() ?? "UNKNOWN SHARE"
|
? dto.album?.albumName.toUpperCase() ?? "UNKNOWN SHARE"
|
||||||
: "INDIVIDUAL SHARE",
|
: "INDIVIDUAL SHARE",
|
||||||
thumbAssetId = dto.type == SharedLinkType.ALBUM
|
thumbAssetId = dto.type == SharedLinkType.ALBUM
|
||||||
? dto.album?.albumThumbnailAssetId.unwrapOrNull()
|
? dto.album?.albumThumbnailAssetId?.unwrapOrNull()
|
||||||
: dto.assets.isNotEmpty
|
: dto.assets.isNotEmpty
|
||||||
? dto.assets[0].id
|
? dto.assets[0].id
|
||||||
: null;
|
: null;
|
||||||
|
@ -40,7 +40,7 @@ final getAllPlacesProvider =
|
|||||||
final curatedContent = assetPlaces
|
final curatedContent = assetPlaces
|
||||||
.map(
|
.map(
|
||||||
(data) => SearchCuratedContent(
|
(data) => SearchCuratedContent(
|
||||||
label: data.exifInfo!.city.unwrap(),
|
label: data.exifInfo!.city!.unwrap(),
|
||||||
id: data.id,
|
id: data.id,
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
@ -61,7 +61,7 @@ class ActivityApiRepository extends ApiRepository
|
|||||||
? ActivityType.comment
|
? ActivityType.comment
|
||||||
: ActivityType.like,
|
: ActivityType.like,
|
||||||
user: UserConverter.fromSimpleUserDto(dto.user),
|
user: UserConverter.fromSimpleUserDto(dto.user),
|
||||||
assetId: dto.assetId.unwrapOrNull(),
|
assetId: dto.assetId?.unwrapOrNull(),
|
||||||
comment: dto.comment.unwrapOrNull(),
|
comment: dto.comment?.unwrapOrNull(),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -168,7 +168,7 @@ class AlbumApiRepository extends ApiRepository implements IAlbumApiRepository {
|
|||||||
album.remoteAssetCount = dto.assetCount;
|
album.remoteAssetCount = dto.assetCount;
|
||||||
album.owner.value =
|
album.owner.value =
|
||||||
entity.User.fromDto(UserConverter.fromSimpleUserDto(dto.owner));
|
entity.User.fromDto(UserConverter.fromSimpleUserDto(dto.owner));
|
||||||
album.remoteThumbnailAssetId = dto.albumThumbnailAssetId.unwrapOrNull();
|
album.remoteThumbnailAssetId = dto.albumThumbnailAssetId?.unwrapOrNull();
|
||||||
final users = dto.albumUsers
|
final users = dto.albumUsers
|
||||||
.map((albumUser) => UserConverter.fromSimpleUserDto(albumUser.user));
|
.map((albumUser) => UserConverter.fromSimpleUserDto(albumUser.user));
|
||||||
album.sharedUsers.addAll(users.map(entity.User.fromDto));
|
album.sharedUsers.addAll(users.map(entity.User.fromDto));
|
||||||
|
@ -43,7 +43,7 @@ class AssetApiRepository extends ApiRepository implements IAssetApiRepository {
|
|||||||
),
|
),
|
||||||
);
|
);
|
||||||
result.addAll(response.assets.items.map(Asset.remote));
|
result.addAll(response.assets.items.map(Asset.remote));
|
||||||
hasNext = response.assets.nextPage.unwrapOrNull() != null;
|
hasNext = response.assets.nextPage?.unwrapOrNull() != null;
|
||||||
currentPage++;
|
currentPage++;
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
|
@ -29,7 +29,7 @@ class PersonApiRepository extends ApiRepository
|
|||||||
}
|
}
|
||||||
|
|
||||||
static Person _toPerson(PersonResponseDto dto) => Person(
|
static Person _toPerson(PersonResponseDto dto) => Person(
|
||||||
birthDate: dto.birthDate.unwrapOrNull(),
|
birthDate: dto.birthDate?.unwrapOrNull(),
|
||||||
id: dto.id,
|
id: dto.id,
|
||||||
isHidden: dto.isHidden,
|
isHidden: dto.isHidden,
|
||||||
name: dto.name,
|
name: dto.name,
|
||||||
|
@ -119,7 +119,7 @@ class SearchService {
|
|||||||
assets: await _assetRepository.getAllByRemoteId(
|
assets: await _assetRepository.getAllByRemoteId(
|
||||||
response.assets.items.map((e) => e.id),
|
response.assets.items.map((e) => e.id),
|
||||||
),
|
),
|
||||||
nextPage: response.assets.nextPage.unwrapOrNull()?.toInt(),
|
nextPage: response.assets.nextPage?.unwrapOrNull()?.toInt(),
|
||||||
);
|
);
|
||||||
} catch (error, stackTrace) {
|
} catch (error, stackTrace) {
|
||||||
_log.severe("Failed to search for assets", error, stackTrace);
|
_log.severe("Failed to search for assets", error, stackTrace);
|
||||||
|
@ -45,9 +45,9 @@ class PeopleInfo extends ConsumerWidget {
|
|||||||
(p) => SearchCuratedContent(
|
(p) => SearchCuratedContent(
|
||||||
id: p.id,
|
id: p.id,
|
||||||
label: p.name,
|
label: p.name,
|
||||||
subtitle: p.birthDate.unwrapOrNull() != null &&
|
subtitle: p.birthDate?.unwrapOrNull() != null &&
|
||||||
p.birthDate.unwrap().isBefore(asset.fileCreatedAt)
|
p.birthDate!.unwrap().isBefore(asset.fileCreatedAt)
|
||||||
? _formatAge(p.birthDate.unwrap(), asset.fileCreatedAt)
|
? _formatAge(p.birthDate!.unwrap(), asset.fileCreatedAt)
|
||||||
: null,
|
: null,
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
20
mobile/openapi/lib/model/activity_response_dto.dart
generated
20
mobile/openapi/lib/model/activity_response_dto.dart
generated
@ -13,17 +13,17 @@ part of openapi.api;
|
|||||||
class ActivityResponseDto {
|
class ActivityResponseDto {
|
||||||
/// Returns a new [ActivityResponseDto] instance.
|
/// Returns a new [ActivityResponseDto] instance.
|
||||||
ActivityResponseDto({
|
ActivityResponseDto({
|
||||||
this.assetId = const None(),
|
required this.assetId,
|
||||||
this.comment = const None(),
|
this.comment,
|
||||||
required this.createdAt,
|
required this.createdAt,
|
||||||
required this.id,
|
required this.id,
|
||||||
required this.type,
|
required this.type,
|
||||||
required this.user,
|
required this.user,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<String> assetId;
|
Option<String>? assetId;
|
||||||
|
|
||||||
Option<String> comment;
|
Option<String>? comment;
|
||||||
|
|
||||||
DateTime createdAt;
|
DateTime createdAt;
|
||||||
|
|
||||||
@ -45,8 +45,8 @@ class ActivityResponseDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(assetId.hashCode) +
|
(assetId == null ? 0 : assetId!.hashCode) +
|
||||||
(comment.hashCode) +
|
(comment == null ? 0 : comment!.hashCode) +
|
||||||
(createdAt.hashCode) +
|
(createdAt.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(type.hashCode) +
|
(type.hashCode) +
|
||||||
@ -57,17 +57,17 @@ class ActivityResponseDto {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.assetId.unwrapOrNull() != null) {
|
if (this.assetId?.isSome ?? false) {
|
||||||
json[r'assetId'] = this.assetId;
|
json[r'assetId'] = this.assetId;
|
||||||
} else {
|
} else {
|
||||||
if(this.assetId.isSome) {
|
if(this.assetId?.isNone ?? false) {
|
||||||
json[r'assetId'] = null;
|
json[r'assetId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.comment.unwrapOrNull() != null) {
|
if (this.comment?.isSome ?? false) {
|
||||||
json[r'comment'] = this.comment;
|
json[r'comment'] = this.comment;
|
||||||
} else {
|
} else {
|
||||||
if(this.comment.isSome) {
|
if(this.comment?.isNone ?? false) {
|
||||||
json[r'comment'] = null;
|
json[r'comment'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
10
mobile/openapi/lib/model/album_response_dto.dart
generated
10
mobile/openapi/lib/model/album_response_dto.dart
generated
@ -14,7 +14,7 @@ class AlbumResponseDto {
|
|||||||
/// Returns a new [AlbumResponseDto] instance.
|
/// Returns a new [AlbumResponseDto] instance.
|
||||||
AlbumResponseDto({
|
AlbumResponseDto({
|
||||||
required this.albumName,
|
required this.albumName,
|
||||||
this.albumThumbnailAssetId = const None(),
|
required this.albumThumbnailAssetId,
|
||||||
this.albumUsers = const [],
|
this.albumUsers = const [],
|
||||||
required this.assetCount,
|
required this.assetCount,
|
||||||
this.assets = const [],
|
this.assets = const [],
|
||||||
@ -35,7 +35,7 @@ class AlbumResponseDto {
|
|||||||
|
|
||||||
String albumName;
|
String albumName;
|
||||||
|
|
||||||
Option<String> albumThumbnailAssetId;
|
Option<String>? albumThumbnailAssetId;
|
||||||
|
|
||||||
List<AlbumUserResponseDto> albumUsers;
|
List<AlbumUserResponseDto> albumUsers;
|
||||||
|
|
||||||
@ -118,7 +118,7 @@ class AlbumResponseDto {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(albumName.hashCode) +
|
(albumName.hashCode) +
|
||||||
(albumThumbnailAssetId.hashCode) +
|
(albumThumbnailAssetId == null ? 0 : albumThumbnailAssetId!.hashCode) +
|
||||||
(albumUsers.hashCode) +
|
(albumUsers.hashCode) +
|
||||||
(assetCount.hashCode) +
|
(assetCount.hashCode) +
|
||||||
(assets.hashCode) +
|
(assets.hashCode) +
|
||||||
@ -142,10 +142,10 @@ class AlbumResponseDto {
|
|||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
json[r'albumName'] = this.albumName;
|
json[r'albumName'] = this.albumName;
|
||||||
if (this.albumThumbnailAssetId.unwrapOrNull() != null) {
|
if (this.albumThumbnailAssetId?.isSome ?? false) {
|
||||||
json[r'albumThumbnailAssetId'] = this.albumThumbnailAssetId;
|
json[r'albumThumbnailAssetId'] = this.albumThumbnailAssetId;
|
||||||
} else {
|
} else {
|
||||||
if(this.albumThumbnailAssetId.isSome) {
|
if(this.albumThumbnailAssetId?.isNone ?? false) {
|
||||||
json[r'albumThumbnailAssetId'] = null;
|
json[r'albumThumbnailAssetId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
10
mobile/openapi/lib/model/asset_bulk_update_dto.dart
generated
10
mobile/openapi/lib/model/asset_bulk_update_dto.dart
generated
@ -14,7 +14,7 @@ class AssetBulkUpdateDto {
|
|||||||
/// Returns a new [AssetBulkUpdateDto] instance.
|
/// Returns a new [AssetBulkUpdateDto] instance.
|
||||||
AssetBulkUpdateDto({
|
AssetBulkUpdateDto({
|
||||||
this.dateTimeOriginal,
|
this.dateTimeOriginal,
|
||||||
this.duplicateId = const None(),
|
this.duplicateId,
|
||||||
this.ids = const [],
|
this.ids = const [],
|
||||||
this.isFavorite,
|
this.isFavorite,
|
||||||
this.latitude,
|
this.latitude,
|
||||||
@ -31,7 +31,7 @@ class AssetBulkUpdateDto {
|
|||||||
///
|
///
|
||||||
String? dateTimeOriginal;
|
String? dateTimeOriginal;
|
||||||
|
|
||||||
Option<String> duplicateId;
|
Option<String>? duplicateId;
|
||||||
|
|
||||||
List<String> ids;
|
List<String> ids;
|
||||||
|
|
||||||
@ -92,7 +92,7 @@ class AssetBulkUpdateDto {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(dateTimeOriginal == null ? 0 : dateTimeOriginal!.hashCode) +
|
(dateTimeOriginal == null ? 0 : dateTimeOriginal!.hashCode) +
|
||||||
(duplicateId.hashCode) +
|
(duplicateId == null ? 0 : duplicateId!.hashCode) +
|
||||||
(ids.hashCode) +
|
(ids.hashCode) +
|
||||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||||
(latitude == null ? 0 : latitude!.hashCode) +
|
(latitude == null ? 0 : latitude!.hashCode) +
|
||||||
@ -110,10 +110,10 @@ class AssetBulkUpdateDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'dateTimeOriginal'] = null;
|
// json[r'dateTimeOriginal'] = null;
|
||||||
}
|
}
|
||||||
if (this.duplicateId.unwrapOrNull() != null) {
|
if (this.duplicateId?.isSome ?? false) {
|
||||||
json[r'duplicateId'] = this.duplicateId;
|
json[r'duplicateId'] = this.duplicateId;
|
||||||
} else {
|
} else {
|
||||||
if(this.duplicateId.isSome) {
|
if(this.duplicateId?.isNone ?? false) {
|
||||||
json[r'duplicateId'] = null;
|
json[r'duplicateId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -20,7 +20,7 @@ class AssetFaceResponseDto {
|
|||||||
required this.id,
|
required this.id,
|
||||||
required this.imageHeight,
|
required this.imageHeight,
|
||||||
required this.imageWidth,
|
required this.imageWidth,
|
||||||
this.person = const None(),
|
required this.person,
|
||||||
this.sourceType,
|
this.sourceType,
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -38,7 +38,7 @@ class AssetFaceResponseDto {
|
|||||||
|
|
||||||
int imageWidth;
|
int imageWidth;
|
||||||
|
|
||||||
Option<PersonResponseDto> person;
|
Option<PersonResponseDto>? person;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -70,7 +70,7 @@ class AssetFaceResponseDto {
|
|||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(imageHeight.hashCode) +
|
(imageHeight.hashCode) +
|
||||||
(imageWidth.hashCode) +
|
(imageWidth.hashCode) +
|
||||||
(person.hashCode) +
|
(person == null ? 0 : person!.hashCode) +
|
||||||
(sourceType == null ? 0 : sourceType!.hashCode);
|
(sourceType == null ? 0 : sourceType!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@ -85,10 +85,10 @@ class AssetFaceResponseDto {
|
|||||||
json[r'id'] = this.id;
|
json[r'id'] = this.id;
|
||||||
json[r'imageHeight'] = this.imageHeight;
|
json[r'imageHeight'] = this.imageHeight;
|
||||||
json[r'imageWidth'] = this.imageWidth;
|
json[r'imageWidth'] = this.imageWidth;
|
||||||
if (this.person.unwrapOrNull() != null) {
|
if (this.person?.isSome ?? false) {
|
||||||
json[r'person'] = this.person;
|
json[r'person'] = this.person;
|
||||||
} else {
|
} else {
|
||||||
if(this.person.isSome) {
|
if(this.person?.isNone ?? false) {
|
||||||
json[r'person'] = null;
|
json[r'person'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
50
mobile/openapi/lib/model/asset_response_dto.dart
generated
50
mobile/openapi/lib/model/asset_response_dto.dart
generated
@ -16,7 +16,7 @@ class AssetResponseDto {
|
|||||||
required this.checksum,
|
required this.checksum,
|
||||||
required this.deviceAssetId,
|
required this.deviceAssetId,
|
||||||
required this.deviceId,
|
required this.deviceId,
|
||||||
this.duplicateId = const None(),
|
this.duplicateId,
|
||||||
required this.duration,
|
required this.duration,
|
||||||
this.exifInfo,
|
this.exifInfo,
|
||||||
required this.fileCreatedAt,
|
required this.fileCreatedAt,
|
||||||
@ -27,8 +27,8 @@ class AssetResponseDto {
|
|||||||
required this.isFavorite,
|
required this.isFavorite,
|
||||||
required this.isOffline,
|
required this.isOffline,
|
||||||
required this.isTrashed,
|
required this.isTrashed,
|
||||||
this.libraryId = const None(),
|
this.libraryId,
|
||||||
this.livePhotoVideoId = const None(),
|
this.livePhotoVideoId,
|
||||||
required this.localDateTime,
|
required this.localDateTime,
|
||||||
required this.originalFileName,
|
required this.originalFileName,
|
||||||
this.originalMimeType,
|
this.originalMimeType,
|
||||||
@ -37,9 +37,9 @@ class AssetResponseDto {
|
|||||||
required this.ownerId,
|
required this.ownerId,
|
||||||
this.people = const [],
|
this.people = const [],
|
||||||
this.resized,
|
this.resized,
|
||||||
this.stack = const None(),
|
this.stack,
|
||||||
this.tags = const [],
|
this.tags = const [],
|
||||||
this.thumbhash = const None(),
|
required this.thumbhash,
|
||||||
required this.type,
|
required this.type,
|
||||||
this.unassignedFaces = const [],
|
this.unassignedFaces = const [],
|
||||||
required this.updatedAt,
|
required this.updatedAt,
|
||||||
@ -53,7 +53,7 @@ class AssetResponseDto {
|
|||||||
|
|
||||||
String deviceId;
|
String deviceId;
|
||||||
|
|
||||||
Option<String> duplicateId;
|
Option<String>? duplicateId;
|
||||||
|
|
||||||
String duration;
|
String duration;
|
||||||
|
|
||||||
@ -82,9 +82,9 @@ class AssetResponseDto {
|
|||||||
bool isTrashed;
|
bool isTrashed;
|
||||||
|
|
||||||
/// This property was deprecated in v1.106.0
|
/// This property was deprecated in v1.106.0
|
||||||
Option<String> libraryId;
|
Option<String>? libraryId;
|
||||||
|
|
||||||
Option<String> livePhotoVideoId;
|
Option<String>? livePhotoVideoId;
|
||||||
|
|
||||||
DateTime localDateTime;
|
DateTime localDateTime;
|
||||||
|
|
||||||
@ -121,11 +121,11 @@ class AssetResponseDto {
|
|||||||
///
|
///
|
||||||
bool? resized;
|
bool? resized;
|
||||||
|
|
||||||
Option<AssetStackResponseDto> stack;
|
Option<AssetStackResponseDto>? stack;
|
||||||
|
|
||||||
List<TagResponseDto> tags;
|
List<TagResponseDto> tags;
|
||||||
|
|
||||||
Option<String> thumbhash;
|
Option<String>? thumbhash;
|
||||||
|
|
||||||
AssetTypeEnum type;
|
AssetTypeEnum type;
|
||||||
|
|
||||||
@ -175,7 +175,7 @@ class AssetResponseDto {
|
|||||||
(checksum.hashCode) +
|
(checksum.hashCode) +
|
||||||
(deviceAssetId.hashCode) +
|
(deviceAssetId.hashCode) +
|
||||||
(deviceId.hashCode) +
|
(deviceId.hashCode) +
|
||||||
(duplicateId.hashCode) +
|
(duplicateId == null ? 0 : duplicateId!.hashCode) +
|
||||||
(duration.hashCode) +
|
(duration.hashCode) +
|
||||||
(exifInfo == null ? 0 : exifInfo!.hashCode) +
|
(exifInfo == null ? 0 : exifInfo!.hashCode) +
|
||||||
(fileCreatedAt.hashCode) +
|
(fileCreatedAt.hashCode) +
|
||||||
@ -186,8 +186,8 @@ class AssetResponseDto {
|
|||||||
(isFavorite.hashCode) +
|
(isFavorite.hashCode) +
|
||||||
(isOffline.hashCode) +
|
(isOffline.hashCode) +
|
||||||
(isTrashed.hashCode) +
|
(isTrashed.hashCode) +
|
||||||
(libraryId.hashCode) +
|
(libraryId == null ? 0 : libraryId!.hashCode) +
|
||||||
(livePhotoVideoId.hashCode) +
|
(livePhotoVideoId == null ? 0 : livePhotoVideoId!.hashCode) +
|
||||||
(localDateTime.hashCode) +
|
(localDateTime.hashCode) +
|
||||||
(originalFileName.hashCode) +
|
(originalFileName.hashCode) +
|
||||||
(originalMimeType == null ? 0 : originalMimeType!.hashCode) +
|
(originalMimeType == null ? 0 : originalMimeType!.hashCode) +
|
||||||
@ -196,9 +196,9 @@ class AssetResponseDto {
|
|||||||
(ownerId.hashCode) +
|
(ownerId.hashCode) +
|
||||||
(people.hashCode) +
|
(people.hashCode) +
|
||||||
(resized == null ? 0 : resized!.hashCode) +
|
(resized == null ? 0 : resized!.hashCode) +
|
||||||
(stack.hashCode) +
|
(stack == null ? 0 : stack!.hashCode) +
|
||||||
(tags.hashCode) +
|
(tags.hashCode) +
|
||||||
(thumbhash.hashCode) +
|
(thumbhash == null ? 0 : thumbhash!.hashCode) +
|
||||||
(type.hashCode) +
|
(type.hashCode) +
|
||||||
(unassignedFaces.hashCode) +
|
(unassignedFaces.hashCode) +
|
||||||
(updatedAt.hashCode) +
|
(updatedAt.hashCode) +
|
||||||
@ -212,10 +212,10 @@ class AssetResponseDto {
|
|||||||
json[r'checksum'] = this.checksum;
|
json[r'checksum'] = this.checksum;
|
||||||
json[r'deviceAssetId'] = this.deviceAssetId;
|
json[r'deviceAssetId'] = this.deviceAssetId;
|
||||||
json[r'deviceId'] = this.deviceId;
|
json[r'deviceId'] = this.deviceId;
|
||||||
if (this.duplicateId.unwrapOrNull() != null) {
|
if (this.duplicateId?.isSome ?? false) {
|
||||||
json[r'duplicateId'] = this.duplicateId;
|
json[r'duplicateId'] = this.duplicateId;
|
||||||
} else {
|
} else {
|
||||||
if(this.duplicateId.isSome) {
|
if(this.duplicateId?.isNone ?? false) {
|
||||||
json[r'duplicateId'] = null;
|
json[r'duplicateId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -233,17 +233,17 @@ class AssetResponseDto {
|
|||||||
json[r'isFavorite'] = this.isFavorite;
|
json[r'isFavorite'] = this.isFavorite;
|
||||||
json[r'isOffline'] = this.isOffline;
|
json[r'isOffline'] = this.isOffline;
|
||||||
json[r'isTrashed'] = this.isTrashed;
|
json[r'isTrashed'] = this.isTrashed;
|
||||||
if (this.libraryId.unwrapOrNull() != null) {
|
if (this.libraryId?.isSome ?? false) {
|
||||||
json[r'libraryId'] = this.libraryId;
|
json[r'libraryId'] = this.libraryId;
|
||||||
} else {
|
} else {
|
||||||
if(this.libraryId.isSome) {
|
if(this.libraryId?.isNone ?? false) {
|
||||||
json[r'libraryId'] = null;
|
json[r'libraryId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.livePhotoVideoId.unwrapOrNull() != null) {
|
if (this.livePhotoVideoId?.isSome ?? false) {
|
||||||
json[r'livePhotoVideoId'] = this.livePhotoVideoId;
|
json[r'livePhotoVideoId'] = this.livePhotoVideoId;
|
||||||
} else {
|
} else {
|
||||||
if(this.livePhotoVideoId.isSome) {
|
if(this.livePhotoVideoId?.isNone ?? false) {
|
||||||
json[r'livePhotoVideoId'] = null;
|
json[r'livePhotoVideoId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -267,18 +267,18 @@ class AssetResponseDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'resized'] = null;
|
// json[r'resized'] = null;
|
||||||
}
|
}
|
||||||
if (this.stack.unwrapOrNull() != null) {
|
if (this.stack?.isSome ?? false) {
|
||||||
json[r'stack'] = this.stack;
|
json[r'stack'] = this.stack;
|
||||||
} else {
|
} else {
|
||||||
if(this.stack.isSome) {
|
if(this.stack?.isNone ?? false) {
|
||||||
json[r'stack'] = null;
|
json[r'stack'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
json[r'tags'] = this.tags;
|
json[r'tags'] = this.tags;
|
||||||
if (this.thumbhash.unwrapOrNull() != null) {
|
if (this.thumbhash?.isSome ?? false) {
|
||||||
json[r'thumbhash'] = this.thumbhash;
|
json[r'thumbhash'] = this.thumbhash;
|
||||||
} else {
|
} else {
|
||||||
if(this.thumbhash.isSome) {
|
if(this.thumbhash?.isNone ?? false) {
|
||||||
json[r'thumbhash'] = null;
|
json[r'thumbhash'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
224
mobile/openapi/lib/model/exif_response_dto.dart
generated
224
mobile/openapi/lib/model/exif_response_dto.dart
generated
@ -13,73 +13,73 @@ part of openapi.api;
|
|||||||
class ExifResponseDto {
|
class ExifResponseDto {
|
||||||
/// Returns a new [ExifResponseDto] instance.
|
/// Returns a new [ExifResponseDto] instance.
|
||||||
ExifResponseDto({
|
ExifResponseDto({
|
||||||
this.city = const None(),
|
this.city,
|
||||||
this.country = const None(),
|
this.country,
|
||||||
this.dateTimeOriginal = const None(),
|
this.dateTimeOriginal,
|
||||||
this.description = const None(),
|
this.description,
|
||||||
this.exifImageHeight = const None(),
|
this.exifImageHeight,
|
||||||
this.exifImageWidth = const None(),
|
this.exifImageWidth,
|
||||||
this.exposureTime = const None(),
|
this.exposureTime,
|
||||||
this.fNumber = const None(),
|
this.fNumber,
|
||||||
this.fileSizeInByte = const None(),
|
this.fileSizeInByte,
|
||||||
this.focalLength = const None(),
|
this.focalLength,
|
||||||
this.iso = const None(),
|
this.iso,
|
||||||
this.latitude = const None(),
|
this.latitude,
|
||||||
this.lensModel = const None(),
|
this.lensModel,
|
||||||
this.longitude = const None(),
|
this.longitude,
|
||||||
this.make = const None(),
|
this.make,
|
||||||
this.model = const None(),
|
this.model,
|
||||||
this.modifyDate = const None(),
|
this.modifyDate,
|
||||||
this.orientation = const None(),
|
this.orientation,
|
||||||
this.projectionType = const None(),
|
this.projectionType,
|
||||||
this.rating = const None(),
|
this.rating,
|
||||||
this.state = const None(),
|
this.state,
|
||||||
this.timeZone = const None(),
|
this.timeZone,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<String> city;
|
Option<String>? city;
|
||||||
|
|
||||||
Option<String> country;
|
Option<String>? country;
|
||||||
|
|
||||||
Option<DateTime> dateTimeOriginal;
|
Option<DateTime>? dateTimeOriginal;
|
||||||
|
|
||||||
Option<String> description;
|
Option<String>? description;
|
||||||
|
|
||||||
Option<num> exifImageHeight;
|
Option<num>? exifImageHeight;
|
||||||
|
|
||||||
Option<num> exifImageWidth;
|
Option<num>? exifImageWidth;
|
||||||
|
|
||||||
Option<String> exposureTime;
|
Option<String>? exposureTime;
|
||||||
|
|
||||||
Option<num> fNumber;
|
Option<num>? fNumber;
|
||||||
|
|
||||||
Option<int> fileSizeInByte;
|
Option<int>? fileSizeInByte;
|
||||||
|
|
||||||
Option<num> focalLength;
|
Option<num>? focalLength;
|
||||||
|
|
||||||
Option<num> iso;
|
Option<num>? iso;
|
||||||
|
|
||||||
Option<num> latitude;
|
Option<num>? latitude;
|
||||||
|
|
||||||
Option<String> lensModel;
|
Option<String>? lensModel;
|
||||||
|
|
||||||
Option<num> longitude;
|
Option<num>? longitude;
|
||||||
|
|
||||||
Option<String> make;
|
Option<String>? make;
|
||||||
|
|
||||||
Option<String> model;
|
Option<String>? model;
|
||||||
|
|
||||||
Option<DateTime> modifyDate;
|
Option<DateTime>? modifyDate;
|
||||||
|
|
||||||
Option<String> orientation;
|
Option<String>? orientation;
|
||||||
|
|
||||||
Option<String> projectionType;
|
Option<String>? projectionType;
|
||||||
|
|
||||||
Option<num> rating;
|
Option<num>? rating;
|
||||||
|
|
||||||
Option<String> state;
|
Option<String>? state;
|
||||||
|
|
||||||
Option<String> timeZone;
|
Option<String>? timeZone;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is ExifResponseDto &&
|
bool operator ==(Object other) => identical(this, other) || other is ExifResponseDto &&
|
||||||
@ -109,185 +109,185 @@ class ExifResponseDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(city.hashCode) +
|
(city == null ? 0 : city!.hashCode) +
|
||||||
(country.hashCode) +
|
(country == null ? 0 : country!.hashCode) +
|
||||||
(dateTimeOriginal.hashCode) +
|
(dateTimeOriginal == null ? 0 : dateTimeOriginal!.hashCode) +
|
||||||
(description.hashCode) +
|
(description == null ? 0 : description!.hashCode) +
|
||||||
(exifImageHeight.hashCode) +
|
(exifImageHeight == null ? 0 : exifImageHeight!.hashCode) +
|
||||||
(exifImageWidth.hashCode) +
|
(exifImageWidth == null ? 0 : exifImageWidth!.hashCode) +
|
||||||
(exposureTime.hashCode) +
|
(exposureTime == null ? 0 : exposureTime!.hashCode) +
|
||||||
(fNumber.hashCode) +
|
(fNumber == null ? 0 : fNumber!.hashCode) +
|
||||||
(fileSizeInByte.hashCode) +
|
(fileSizeInByte == null ? 0 : fileSizeInByte!.hashCode) +
|
||||||
(focalLength.hashCode) +
|
(focalLength == null ? 0 : focalLength!.hashCode) +
|
||||||
(iso.hashCode) +
|
(iso == null ? 0 : iso!.hashCode) +
|
||||||
(latitude.hashCode) +
|
(latitude == null ? 0 : latitude!.hashCode) +
|
||||||
(lensModel.hashCode) +
|
(lensModel == null ? 0 : lensModel!.hashCode) +
|
||||||
(longitude.hashCode) +
|
(longitude == null ? 0 : longitude!.hashCode) +
|
||||||
(make.hashCode) +
|
(make == null ? 0 : make!.hashCode) +
|
||||||
(model.hashCode) +
|
(model == null ? 0 : model!.hashCode) +
|
||||||
(modifyDate.hashCode) +
|
(modifyDate == null ? 0 : modifyDate!.hashCode) +
|
||||||
(orientation.hashCode) +
|
(orientation == null ? 0 : orientation!.hashCode) +
|
||||||
(projectionType.hashCode) +
|
(projectionType == null ? 0 : projectionType!.hashCode) +
|
||||||
(rating.hashCode) +
|
(rating == null ? 0 : rating!.hashCode) +
|
||||||
(state.hashCode) +
|
(state == null ? 0 : state!.hashCode) +
|
||||||
(timeZone.hashCode);
|
(timeZone == null ? 0 : timeZone!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'ExifResponseDto[city=$city, country=$country, dateTimeOriginal=$dateTimeOriginal, description=$description, exifImageHeight=$exifImageHeight, exifImageWidth=$exifImageWidth, exposureTime=$exposureTime, fNumber=$fNumber, fileSizeInByte=$fileSizeInByte, focalLength=$focalLength, iso=$iso, latitude=$latitude, lensModel=$lensModel, longitude=$longitude, make=$make, model=$model, modifyDate=$modifyDate, orientation=$orientation, projectionType=$projectionType, rating=$rating, state=$state, timeZone=$timeZone]';
|
String toString() => 'ExifResponseDto[city=$city, country=$country, dateTimeOriginal=$dateTimeOriginal, description=$description, exifImageHeight=$exifImageHeight, exifImageWidth=$exifImageWidth, exposureTime=$exposureTime, fNumber=$fNumber, fileSizeInByte=$fileSizeInByte, focalLength=$focalLength, iso=$iso, latitude=$latitude, lensModel=$lensModel, longitude=$longitude, make=$make, model=$model, modifyDate=$modifyDate, orientation=$orientation, projectionType=$projectionType, rating=$rating, state=$state, timeZone=$timeZone]';
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.city.unwrapOrNull() != null) {
|
if (this.city?.isSome ?? false) {
|
||||||
json[r'city'] = this.city;
|
json[r'city'] = this.city;
|
||||||
} else {
|
} else {
|
||||||
if(this.city.isSome) {
|
if(this.city?.isNone ?? false) {
|
||||||
json[r'city'] = null;
|
json[r'city'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.country.unwrapOrNull() != null) {
|
if (this.country?.isSome ?? false) {
|
||||||
json[r'country'] = this.country;
|
json[r'country'] = this.country;
|
||||||
} else {
|
} else {
|
||||||
if(this.country.isSome) {
|
if(this.country?.isNone ?? false) {
|
||||||
json[r'country'] = null;
|
json[r'country'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.dateTimeOriginal.unwrapOrNull() != null) {
|
if (this.dateTimeOriginal?.isSome ?? false) {
|
||||||
json[r'dateTimeOriginal'] = this.dateTimeOriginal.unwrap().toUtc().toIso8601String();
|
json[r'dateTimeOriginal'] = this.dateTimeOriginal!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.dateTimeOriginal.isSome) {
|
if(this.dateTimeOriginal?.isNone ?? false) {
|
||||||
json[r'dateTimeOriginal'] = null;
|
json[r'dateTimeOriginal'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.description.unwrapOrNull() != null) {
|
if (this.description?.isSome ?? false) {
|
||||||
json[r'description'] = this.description;
|
json[r'description'] = this.description;
|
||||||
} else {
|
} else {
|
||||||
if(this.description.isSome) {
|
if(this.description?.isNone ?? false) {
|
||||||
json[r'description'] = null;
|
json[r'description'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.exifImageHeight.unwrapOrNull() != null) {
|
if (this.exifImageHeight?.isSome ?? false) {
|
||||||
json[r'exifImageHeight'] = this.exifImageHeight;
|
json[r'exifImageHeight'] = this.exifImageHeight;
|
||||||
} else {
|
} else {
|
||||||
if(this.exifImageHeight.isSome) {
|
if(this.exifImageHeight?.isNone ?? false) {
|
||||||
json[r'exifImageHeight'] = null;
|
json[r'exifImageHeight'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.exifImageWidth.unwrapOrNull() != null) {
|
if (this.exifImageWidth?.isSome ?? false) {
|
||||||
json[r'exifImageWidth'] = this.exifImageWidth;
|
json[r'exifImageWidth'] = this.exifImageWidth;
|
||||||
} else {
|
} else {
|
||||||
if(this.exifImageWidth.isSome) {
|
if(this.exifImageWidth?.isNone ?? false) {
|
||||||
json[r'exifImageWidth'] = null;
|
json[r'exifImageWidth'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.exposureTime.unwrapOrNull() != null) {
|
if (this.exposureTime?.isSome ?? false) {
|
||||||
json[r'exposureTime'] = this.exposureTime;
|
json[r'exposureTime'] = this.exposureTime;
|
||||||
} else {
|
} else {
|
||||||
if(this.exposureTime.isSome) {
|
if(this.exposureTime?.isNone ?? false) {
|
||||||
json[r'exposureTime'] = null;
|
json[r'exposureTime'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.fNumber.unwrapOrNull() != null) {
|
if (this.fNumber?.isSome ?? false) {
|
||||||
json[r'fNumber'] = this.fNumber;
|
json[r'fNumber'] = this.fNumber;
|
||||||
} else {
|
} else {
|
||||||
if(this.fNumber.isSome) {
|
if(this.fNumber?.isNone ?? false) {
|
||||||
json[r'fNumber'] = null;
|
json[r'fNumber'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.fileSizeInByte.unwrapOrNull() != null) {
|
if (this.fileSizeInByte?.isSome ?? false) {
|
||||||
json[r'fileSizeInByte'] = this.fileSizeInByte;
|
json[r'fileSizeInByte'] = this.fileSizeInByte;
|
||||||
} else {
|
} else {
|
||||||
if(this.fileSizeInByte.isSome) {
|
if(this.fileSizeInByte?.isNone ?? false) {
|
||||||
json[r'fileSizeInByte'] = null;
|
json[r'fileSizeInByte'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.focalLength.unwrapOrNull() != null) {
|
if (this.focalLength?.isSome ?? false) {
|
||||||
json[r'focalLength'] = this.focalLength;
|
json[r'focalLength'] = this.focalLength;
|
||||||
} else {
|
} else {
|
||||||
if(this.focalLength.isSome) {
|
if(this.focalLength?.isNone ?? false) {
|
||||||
json[r'focalLength'] = null;
|
json[r'focalLength'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.iso.unwrapOrNull() != null) {
|
if (this.iso?.isSome ?? false) {
|
||||||
json[r'iso'] = this.iso;
|
json[r'iso'] = this.iso;
|
||||||
} else {
|
} else {
|
||||||
if(this.iso.isSome) {
|
if(this.iso?.isNone ?? false) {
|
||||||
json[r'iso'] = null;
|
json[r'iso'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.latitude.unwrapOrNull() != null) {
|
if (this.latitude?.isSome ?? false) {
|
||||||
json[r'latitude'] = this.latitude;
|
json[r'latitude'] = this.latitude;
|
||||||
} else {
|
} else {
|
||||||
if(this.latitude.isSome) {
|
if(this.latitude?.isNone ?? false) {
|
||||||
json[r'latitude'] = null;
|
json[r'latitude'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.lensModel.unwrapOrNull() != null) {
|
if (this.lensModel?.isSome ?? false) {
|
||||||
json[r'lensModel'] = this.lensModel;
|
json[r'lensModel'] = this.lensModel;
|
||||||
} else {
|
} else {
|
||||||
if(this.lensModel.isSome) {
|
if(this.lensModel?.isNone ?? false) {
|
||||||
json[r'lensModel'] = null;
|
json[r'lensModel'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.longitude.unwrapOrNull() != null) {
|
if (this.longitude?.isSome ?? false) {
|
||||||
json[r'longitude'] = this.longitude;
|
json[r'longitude'] = this.longitude;
|
||||||
} else {
|
} else {
|
||||||
if(this.longitude.isSome) {
|
if(this.longitude?.isNone ?? false) {
|
||||||
json[r'longitude'] = null;
|
json[r'longitude'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.make.unwrapOrNull() != null) {
|
if (this.make?.isSome ?? false) {
|
||||||
json[r'make'] = this.make;
|
json[r'make'] = this.make;
|
||||||
} else {
|
} else {
|
||||||
if(this.make.isSome) {
|
if(this.make?.isNone ?? false) {
|
||||||
json[r'make'] = null;
|
json[r'make'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.model.unwrapOrNull() != null) {
|
if (this.model?.isSome ?? false) {
|
||||||
json[r'model'] = this.model;
|
json[r'model'] = this.model;
|
||||||
} else {
|
} else {
|
||||||
if(this.model.isSome) {
|
if(this.model?.isNone ?? false) {
|
||||||
json[r'model'] = null;
|
json[r'model'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.modifyDate.unwrapOrNull() != null) {
|
if (this.modifyDate?.isSome ?? false) {
|
||||||
json[r'modifyDate'] = this.modifyDate.unwrap().toUtc().toIso8601String();
|
json[r'modifyDate'] = this.modifyDate!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.modifyDate.isSome) {
|
if(this.modifyDate?.isNone ?? false) {
|
||||||
json[r'modifyDate'] = null;
|
json[r'modifyDate'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.orientation.unwrapOrNull() != null) {
|
if (this.orientation?.isSome ?? false) {
|
||||||
json[r'orientation'] = this.orientation;
|
json[r'orientation'] = this.orientation;
|
||||||
} else {
|
} else {
|
||||||
if(this.orientation.isSome) {
|
if(this.orientation?.isNone ?? false) {
|
||||||
json[r'orientation'] = null;
|
json[r'orientation'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.projectionType.unwrapOrNull() != null) {
|
if (this.projectionType?.isSome ?? false) {
|
||||||
json[r'projectionType'] = this.projectionType;
|
json[r'projectionType'] = this.projectionType;
|
||||||
} else {
|
} else {
|
||||||
if(this.projectionType.isSome) {
|
if(this.projectionType?.isNone ?? false) {
|
||||||
json[r'projectionType'] = null;
|
json[r'projectionType'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.rating.unwrapOrNull() != null) {
|
if (this.rating?.isSome ?? false) {
|
||||||
json[r'rating'] = this.rating;
|
json[r'rating'] = this.rating;
|
||||||
} else {
|
} else {
|
||||||
if(this.rating.isSome) {
|
if(this.rating?.isNone ?? false) {
|
||||||
json[r'rating'] = null;
|
json[r'rating'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.state.unwrapOrNull() != null) {
|
if (this.state?.isSome ?? false) {
|
||||||
json[r'state'] = this.state;
|
json[r'state'] = this.state;
|
||||||
} else {
|
} else {
|
||||||
if(this.state.isSome) {
|
if(this.state?.isNone ?? false) {
|
||||||
json[r'state'] = null;
|
json[r'state'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.timeZone.unwrapOrNull() != null) {
|
if (this.timeZone?.isSome ?? false) {
|
||||||
json[r'timeZone'] = this.timeZone;
|
json[r'timeZone'] = this.timeZone;
|
||||||
} else {
|
} else {
|
||||||
if(this.timeZone.isSome) {
|
if(this.timeZone?.isNone ?? false) {
|
||||||
json[r'timeZone'] = null;
|
json[r'timeZone'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
12
mobile/openapi/lib/model/library_response_dto.dart
generated
12
mobile/openapi/lib/model/library_response_dto.dart
generated
@ -20,7 +20,7 @@ class LibraryResponseDto {
|
|||||||
this.importPaths = const [],
|
this.importPaths = const [],
|
||||||
required this.name,
|
required this.name,
|
||||||
required this.ownerId,
|
required this.ownerId,
|
||||||
this.refreshedAt = const None(),
|
required this.refreshedAt,
|
||||||
required this.updatedAt,
|
required this.updatedAt,
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -38,7 +38,7 @@ class LibraryResponseDto {
|
|||||||
|
|
||||||
String ownerId;
|
String ownerId;
|
||||||
|
|
||||||
Option<DateTime> refreshedAt;
|
Option<DateTime>? refreshedAt;
|
||||||
|
|
||||||
DateTime updatedAt;
|
DateTime updatedAt;
|
||||||
|
|
||||||
@ -64,7 +64,7 @@ class LibraryResponseDto {
|
|||||||
(importPaths.hashCode) +
|
(importPaths.hashCode) +
|
||||||
(name.hashCode) +
|
(name.hashCode) +
|
||||||
(ownerId.hashCode) +
|
(ownerId.hashCode) +
|
||||||
(refreshedAt.hashCode) +
|
(refreshedAt == null ? 0 : refreshedAt!.hashCode) +
|
||||||
(updatedAt.hashCode);
|
(updatedAt.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@ -79,10 +79,10 @@ class LibraryResponseDto {
|
|||||||
json[r'importPaths'] = this.importPaths;
|
json[r'importPaths'] = this.importPaths;
|
||||||
json[r'name'] = this.name;
|
json[r'name'] = this.name;
|
||||||
json[r'ownerId'] = this.ownerId;
|
json[r'ownerId'] = this.ownerId;
|
||||||
if (this.refreshedAt.unwrapOrNull() != null) {
|
if (this.refreshedAt?.isSome ?? false) {
|
||||||
json[r'refreshedAt'] = this.refreshedAt.unwrap().toUtc().toIso8601String();
|
json[r'refreshedAt'] = this.refreshedAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.refreshedAt.isSome) {
|
if(this.refreshedAt?.isNone ?? false) {
|
||||||
json[r'refreshedAt'] = null;
|
json[r'refreshedAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,17 +13,17 @@ part of openapi.api;
|
|||||||
class MapMarkerResponseDto {
|
class MapMarkerResponseDto {
|
||||||
/// Returns a new [MapMarkerResponseDto] instance.
|
/// Returns a new [MapMarkerResponseDto] instance.
|
||||||
MapMarkerResponseDto({
|
MapMarkerResponseDto({
|
||||||
this.city = const None(),
|
required this.city,
|
||||||
this.country = const None(),
|
required this.country,
|
||||||
required this.id,
|
required this.id,
|
||||||
required this.lat,
|
required this.lat,
|
||||||
required this.lon,
|
required this.lon,
|
||||||
this.state = const None(),
|
required this.state,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<String> city;
|
Option<String>? city;
|
||||||
|
|
||||||
Option<String> country;
|
Option<String>? country;
|
||||||
|
|
||||||
String id;
|
String id;
|
||||||
|
|
||||||
@ -31,7 +31,7 @@ class MapMarkerResponseDto {
|
|||||||
|
|
||||||
double lon;
|
double lon;
|
||||||
|
|
||||||
Option<String> state;
|
Option<String>? state;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is MapMarkerResponseDto &&
|
bool operator ==(Object other) => identical(this, other) || other is MapMarkerResponseDto &&
|
||||||
@ -45,39 +45,39 @@ class MapMarkerResponseDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(city.hashCode) +
|
(city == null ? 0 : city!.hashCode) +
|
||||||
(country.hashCode) +
|
(country == null ? 0 : country!.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(lat.hashCode) +
|
(lat.hashCode) +
|
||||||
(lon.hashCode) +
|
(lon.hashCode) +
|
||||||
(state.hashCode);
|
(state == null ? 0 : state!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'MapMarkerResponseDto[city=$city, country=$country, id=$id, lat=$lat, lon=$lon, state=$state]';
|
String toString() => 'MapMarkerResponseDto[city=$city, country=$country, id=$id, lat=$lat, lon=$lon, state=$state]';
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.city.unwrapOrNull() != null) {
|
if (this.city?.isSome ?? false) {
|
||||||
json[r'city'] = this.city;
|
json[r'city'] = this.city;
|
||||||
} else {
|
} else {
|
||||||
if(this.city.isSome) {
|
if(this.city?.isNone ?? false) {
|
||||||
json[r'city'] = null;
|
json[r'city'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.country.unwrapOrNull() != null) {
|
if (this.country?.isSome ?? false) {
|
||||||
json[r'country'] = this.country;
|
json[r'country'] = this.country;
|
||||||
} else {
|
} else {
|
||||||
if(this.country.isSome) {
|
if(this.country?.isNone ?? false) {
|
||||||
json[r'country'] = null;
|
json[r'country'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
json[r'id'] = this.id;
|
json[r'id'] = this.id;
|
||||||
json[r'lat'] = this.lat;
|
json[r'lat'] = this.lat;
|
||||||
json[r'lon'] = this.lon;
|
json[r'lon'] = this.lon;
|
||||||
if (this.state.unwrapOrNull() != null) {
|
if (this.state?.isSome ?? false) {
|
||||||
json[r'state'] = this.state;
|
json[r'state'] = this.state;
|
||||||
} else {
|
} else {
|
||||||
if(this.state.isSome) {
|
if(this.state?.isNone ?? false) {
|
||||||
json[r'state'] = null;
|
json[r'state'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,16 +13,16 @@ part of openapi.api;
|
|||||||
class MapReverseGeocodeResponseDto {
|
class MapReverseGeocodeResponseDto {
|
||||||
/// Returns a new [MapReverseGeocodeResponseDto] instance.
|
/// Returns a new [MapReverseGeocodeResponseDto] instance.
|
||||||
MapReverseGeocodeResponseDto({
|
MapReverseGeocodeResponseDto({
|
||||||
this.city = const None(),
|
required this.city,
|
||||||
this.country = const None(),
|
required this.country,
|
||||||
this.state = const None(),
|
required this.state,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<String> city;
|
Option<String>? city;
|
||||||
|
|
||||||
Option<String> country;
|
Option<String>? country;
|
||||||
|
|
||||||
Option<String> state;
|
Option<String>? state;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is MapReverseGeocodeResponseDto &&
|
bool operator ==(Object other) => identical(this, other) || other is MapReverseGeocodeResponseDto &&
|
||||||
@ -33,33 +33,33 @@ class MapReverseGeocodeResponseDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(city.hashCode) +
|
(city == null ? 0 : city!.hashCode) +
|
||||||
(country.hashCode) +
|
(country == null ? 0 : country!.hashCode) +
|
||||||
(state.hashCode);
|
(state == null ? 0 : state!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'MapReverseGeocodeResponseDto[city=$city, country=$country, state=$state]';
|
String toString() => 'MapReverseGeocodeResponseDto[city=$city, country=$country, state=$state]';
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.city.unwrapOrNull() != null) {
|
if (this.city?.isSome ?? false) {
|
||||||
json[r'city'] = this.city;
|
json[r'city'] = this.city;
|
||||||
} else {
|
} else {
|
||||||
if(this.city.isSome) {
|
if(this.city?.isNone ?? false) {
|
||||||
json[r'city'] = null;
|
json[r'city'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.country.unwrapOrNull() != null) {
|
if (this.country?.isSome ?? false) {
|
||||||
json[r'country'] = this.country;
|
json[r'country'] = this.country;
|
||||||
} else {
|
} else {
|
||||||
if(this.country.isSome) {
|
if(this.country?.isNone ?? false) {
|
||||||
json[r'country'] = null;
|
json[r'country'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.state.unwrapOrNull() != null) {
|
if (this.state?.isSome ?? false) {
|
||||||
json[r'state'] = this.state;
|
json[r'state'] = this.state;
|
||||||
} else {
|
} else {
|
||||||
if(this.state.isSome) {
|
if(this.state?.isNone ?? false) {
|
||||||
json[r'state'] = null;
|
json[r'state'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
60
mobile/openapi/lib/model/metadata_search_dto.dart
generated
60
mobile/openapi/lib/model/metadata_search_dto.dart
generated
@ -14,8 +14,8 @@ class MetadataSearchDto {
|
|||||||
/// Returns a new [MetadataSearchDto] instance.
|
/// Returns a new [MetadataSearchDto] instance.
|
||||||
MetadataSearchDto({
|
MetadataSearchDto({
|
||||||
this.checksum,
|
this.checksum,
|
||||||
this.city = const None(),
|
this.city,
|
||||||
this.country = const None(),
|
this.country,
|
||||||
this.createdAfter,
|
this.createdAfter,
|
||||||
this.createdBefore,
|
this.createdBefore,
|
||||||
this.description,
|
this.description,
|
||||||
@ -28,10 +28,10 @@ class MetadataSearchDto {
|
|||||||
this.isMotion,
|
this.isMotion,
|
||||||
this.isNotInAlbum,
|
this.isNotInAlbum,
|
||||||
this.isOffline,
|
this.isOffline,
|
||||||
this.lensModel = const None(),
|
this.lensModel,
|
||||||
this.libraryId = const None(),
|
this.libraryId,
|
||||||
this.make,
|
this.make,
|
||||||
this.model = const None(),
|
this.model,
|
||||||
this.order = AssetOrder.desc,
|
this.order = AssetOrder.desc,
|
||||||
this.originalFileName,
|
this.originalFileName,
|
||||||
this.originalPath,
|
this.originalPath,
|
||||||
@ -40,7 +40,7 @@ class MetadataSearchDto {
|
|||||||
this.previewPath,
|
this.previewPath,
|
||||||
this.rating,
|
this.rating,
|
||||||
this.size,
|
this.size,
|
||||||
this.state = const None(),
|
this.state,
|
||||||
this.tagIds = const [],
|
this.tagIds = const [],
|
||||||
this.takenAfter,
|
this.takenAfter,
|
||||||
this.takenBefore,
|
this.takenBefore,
|
||||||
@ -65,9 +65,9 @@ class MetadataSearchDto {
|
|||||||
///
|
///
|
||||||
String? checksum;
|
String? checksum;
|
||||||
|
|
||||||
Option<String> city;
|
Option<String>? city;
|
||||||
|
|
||||||
Option<String> country;
|
Option<String>? country;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -165,9 +165,9 @@ class MetadataSearchDto {
|
|||||||
///
|
///
|
||||||
bool? isOffline;
|
bool? isOffline;
|
||||||
|
|
||||||
Option<String> lensModel;
|
Option<String>? lensModel;
|
||||||
|
|
||||||
Option<String> libraryId;
|
Option<String>? libraryId;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -177,7 +177,7 @@ class MetadataSearchDto {
|
|||||||
///
|
///
|
||||||
String? make;
|
String? make;
|
||||||
|
|
||||||
Option<String> model;
|
Option<String>? model;
|
||||||
|
|
||||||
AssetOrder order;
|
AssetOrder order;
|
||||||
|
|
||||||
@ -236,7 +236,7 @@ class MetadataSearchDto {
|
|||||||
///
|
///
|
||||||
num? size;
|
num? size;
|
||||||
|
|
||||||
Option<String> state;
|
Option<String>? state;
|
||||||
|
|
||||||
List<String> tagIds;
|
List<String> tagIds;
|
||||||
|
|
||||||
@ -393,8 +393,8 @@ class MetadataSearchDto {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(checksum == null ? 0 : checksum!.hashCode) +
|
(checksum == null ? 0 : checksum!.hashCode) +
|
||||||
(city.hashCode) +
|
(city == null ? 0 : city!.hashCode) +
|
||||||
(country.hashCode) +
|
(country == null ? 0 : country!.hashCode) +
|
||||||
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
||||||
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
||||||
(description == null ? 0 : description!.hashCode) +
|
(description == null ? 0 : description!.hashCode) +
|
||||||
@ -407,10 +407,10 @@ class MetadataSearchDto {
|
|||||||
(isMotion == null ? 0 : isMotion!.hashCode) +
|
(isMotion == null ? 0 : isMotion!.hashCode) +
|
||||||
(isNotInAlbum == null ? 0 : isNotInAlbum!.hashCode) +
|
(isNotInAlbum == null ? 0 : isNotInAlbum!.hashCode) +
|
||||||
(isOffline == null ? 0 : isOffline!.hashCode) +
|
(isOffline == null ? 0 : isOffline!.hashCode) +
|
||||||
(lensModel.hashCode) +
|
(lensModel == null ? 0 : lensModel!.hashCode) +
|
||||||
(libraryId.hashCode) +
|
(libraryId == null ? 0 : libraryId!.hashCode) +
|
||||||
(make == null ? 0 : make!.hashCode) +
|
(make == null ? 0 : make!.hashCode) +
|
||||||
(model.hashCode) +
|
(model == null ? 0 : model!.hashCode) +
|
||||||
(order.hashCode) +
|
(order.hashCode) +
|
||||||
(originalFileName == null ? 0 : originalFileName!.hashCode) +
|
(originalFileName == null ? 0 : originalFileName!.hashCode) +
|
||||||
(originalPath == null ? 0 : originalPath!.hashCode) +
|
(originalPath == null ? 0 : originalPath!.hashCode) +
|
||||||
@ -419,7 +419,7 @@ class MetadataSearchDto {
|
|||||||
(previewPath == null ? 0 : previewPath!.hashCode) +
|
(previewPath == null ? 0 : previewPath!.hashCode) +
|
||||||
(rating == null ? 0 : rating!.hashCode) +
|
(rating == null ? 0 : rating!.hashCode) +
|
||||||
(size == null ? 0 : size!.hashCode) +
|
(size == null ? 0 : size!.hashCode) +
|
||||||
(state.hashCode) +
|
(state == null ? 0 : state!.hashCode) +
|
||||||
(tagIds.hashCode) +
|
(tagIds.hashCode) +
|
||||||
(takenAfter == null ? 0 : takenAfter!.hashCode) +
|
(takenAfter == null ? 0 : takenAfter!.hashCode) +
|
||||||
(takenBefore == null ? 0 : takenBefore!.hashCode) +
|
(takenBefore == null ? 0 : takenBefore!.hashCode) +
|
||||||
@ -445,17 +445,17 @@ class MetadataSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'checksum'] = null;
|
// json[r'checksum'] = null;
|
||||||
}
|
}
|
||||||
if (this.city.unwrapOrNull() != null) {
|
if (this.city?.isSome ?? false) {
|
||||||
json[r'city'] = this.city;
|
json[r'city'] = this.city;
|
||||||
} else {
|
} else {
|
||||||
if(this.city.isSome) {
|
if(this.city?.isNone ?? false) {
|
||||||
json[r'city'] = null;
|
json[r'city'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.country.unwrapOrNull() != null) {
|
if (this.country?.isSome ?? false) {
|
||||||
json[r'country'] = this.country;
|
json[r'country'] = this.country;
|
||||||
} else {
|
} else {
|
||||||
if(this.country.isSome) {
|
if(this.country?.isNone ?? false) {
|
||||||
json[r'country'] = null;
|
json[r'country'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -519,17 +519,17 @@ class MetadataSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'isOffline'] = null;
|
// json[r'isOffline'] = null;
|
||||||
}
|
}
|
||||||
if (this.lensModel.unwrapOrNull() != null) {
|
if (this.lensModel?.isSome ?? false) {
|
||||||
json[r'lensModel'] = this.lensModel;
|
json[r'lensModel'] = this.lensModel;
|
||||||
} else {
|
} else {
|
||||||
if(this.lensModel.isSome) {
|
if(this.lensModel?.isNone ?? false) {
|
||||||
json[r'lensModel'] = null;
|
json[r'lensModel'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.libraryId.unwrapOrNull() != null) {
|
if (this.libraryId?.isSome ?? false) {
|
||||||
json[r'libraryId'] = this.libraryId;
|
json[r'libraryId'] = this.libraryId;
|
||||||
} else {
|
} else {
|
||||||
if(this.libraryId.isSome) {
|
if(this.libraryId?.isNone ?? false) {
|
||||||
json[r'libraryId'] = null;
|
json[r'libraryId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -538,10 +538,10 @@ class MetadataSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'make'] = null;
|
// json[r'make'] = null;
|
||||||
}
|
}
|
||||||
if (this.model.unwrapOrNull() != null) {
|
if (this.model?.isSome ?? false) {
|
||||||
json[r'model'] = this.model;
|
json[r'model'] = this.model;
|
||||||
} else {
|
} else {
|
||||||
if(this.model.isSome) {
|
if(this.model?.isNone ?? false) {
|
||||||
json[r'model'] = null;
|
json[r'model'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -577,10 +577,10 @@ class MetadataSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'size'] = null;
|
// json[r'size'] = null;
|
||||||
}
|
}
|
||||||
if (this.state.unwrapOrNull() != null) {
|
if (this.state?.isSome ?? false) {
|
||||||
json[r'state'] = this.state;
|
json[r'state'] = this.state;
|
||||||
} else {
|
} else {
|
||||||
if(this.state.isSome) {
|
if(this.state?.isNone ?? false) {
|
||||||
json[r'state'] = null;
|
json[r'state'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -14,9 +14,9 @@ class NotificationCreateDto {
|
|||||||
/// Returns a new [NotificationCreateDto] instance.
|
/// Returns a new [NotificationCreateDto] instance.
|
||||||
NotificationCreateDto({
|
NotificationCreateDto({
|
||||||
this.data,
|
this.data,
|
||||||
this.description = const None(),
|
this.description,
|
||||||
this.level,
|
this.level,
|
||||||
this.readAt = const None(),
|
this.readAt,
|
||||||
required this.title,
|
required this.title,
|
||||||
this.type,
|
this.type,
|
||||||
required this.userId,
|
required this.userId,
|
||||||
@ -30,7 +30,7 @@ class NotificationCreateDto {
|
|||||||
///
|
///
|
||||||
Object? data;
|
Object? data;
|
||||||
|
|
||||||
Option<String> description;
|
Option<String>? description;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -40,7 +40,7 @@ class NotificationCreateDto {
|
|||||||
///
|
///
|
||||||
NotificationLevel? level;
|
NotificationLevel? level;
|
||||||
|
|
||||||
Option<DateTime> readAt;
|
Option<DateTime>? readAt;
|
||||||
|
|
||||||
String title;
|
String title;
|
||||||
|
|
||||||
@ -68,9 +68,9 @@ class NotificationCreateDto {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(data == null ? 0 : data!.hashCode) +
|
(data == null ? 0 : data!.hashCode) +
|
||||||
(description.hashCode) +
|
(description == null ? 0 : description!.hashCode) +
|
||||||
(level == null ? 0 : level!.hashCode) +
|
(level == null ? 0 : level!.hashCode) +
|
||||||
(readAt.hashCode) +
|
(readAt == null ? 0 : readAt!.hashCode) +
|
||||||
(title.hashCode) +
|
(title.hashCode) +
|
||||||
(type == null ? 0 : type!.hashCode) +
|
(type == null ? 0 : type!.hashCode) +
|
||||||
(userId.hashCode);
|
(userId.hashCode);
|
||||||
@ -85,10 +85,10 @@ class NotificationCreateDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'data'] = null;
|
// json[r'data'] = null;
|
||||||
}
|
}
|
||||||
if (this.description.unwrapOrNull() != null) {
|
if (this.description?.isSome ?? false) {
|
||||||
json[r'description'] = this.description;
|
json[r'description'] = this.description;
|
||||||
} else {
|
} else {
|
||||||
if(this.description.isSome) {
|
if(this.description?.isNone ?? false) {
|
||||||
json[r'description'] = null;
|
json[r'description'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -97,10 +97,10 @@ class NotificationCreateDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'level'] = null;
|
// json[r'level'] = null;
|
||||||
}
|
}
|
||||||
if (this.readAt.unwrapOrNull() != null) {
|
if (this.readAt?.isSome ?? false) {
|
||||||
json[r'readAt'] = this.readAt.unwrap().toUtc().toIso8601String();
|
json[r'readAt'] = this.readAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.readAt.isSome) {
|
if(this.readAt?.isNone ?? false) {
|
||||||
json[r'readAt'] = null;
|
json[r'readAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -14,12 +14,12 @@ class NotificationUpdateAllDto {
|
|||||||
/// Returns a new [NotificationUpdateAllDto] instance.
|
/// Returns a new [NotificationUpdateAllDto] instance.
|
||||||
NotificationUpdateAllDto({
|
NotificationUpdateAllDto({
|
||||||
this.ids = const [],
|
this.ids = const [],
|
||||||
this.readAt = const None(),
|
this.readAt,
|
||||||
});
|
});
|
||||||
|
|
||||||
List<String> ids;
|
List<String> ids;
|
||||||
|
|
||||||
Option<DateTime> readAt;
|
Option<DateTime>? readAt;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is NotificationUpdateAllDto &&
|
bool operator ==(Object other) => identical(this, other) || other is NotificationUpdateAllDto &&
|
||||||
@ -30,7 +30,7 @@ class NotificationUpdateAllDto {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(ids.hashCode) +
|
(ids.hashCode) +
|
||||||
(readAt.hashCode);
|
(readAt == null ? 0 : readAt!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'NotificationUpdateAllDto[ids=$ids, readAt=$readAt]';
|
String toString() => 'NotificationUpdateAllDto[ids=$ids, readAt=$readAt]';
|
||||||
@ -38,10 +38,10 @@ class NotificationUpdateAllDto {
|
|||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
json[r'ids'] = this.ids;
|
json[r'ids'] = this.ids;
|
||||||
if (this.readAt.unwrapOrNull() != null) {
|
if (this.readAt?.isSome ?? false) {
|
||||||
json[r'readAt'] = this.readAt.unwrap().toUtc().toIso8601String();
|
json[r'readAt'] = this.readAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.readAt.isSome) {
|
if(this.readAt?.isNone ?? false) {
|
||||||
json[r'readAt'] = null;
|
json[r'readAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,10 +13,10 @@ part of openapi.api;
|
|||||||
class NotificationUpdateDto {
|
class NotificationUpdateDto {
|
||||||
/// Returns a new [NotificationUpdateDto] instance.
|
/// Returns a new [NotificationUpdateDto] instance.
|
||||||
NotificationUpdateDto({
|
NotificationUpdateDto({
|
||||||
this.readAt = const None(),
|
this.readAt,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<DateTime> readAt;
|
Option<DateTime>? readAt;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is NotificationUpdateDto &&
|
bool operator ==(Object other) => identical(this, other) || other is NotificationUpdateDto &&
|
||||||
@ -25,17 +25,17 @@ class NotificationUpdateDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(readAt.hashCode);
|
(readAt == null ? 0 : readAt!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'NotificationUpdateDto[readAt=$readAt]';
|
String toString() => 'NotificationUpdateDto[readAt=$readAt]';
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.readAt.unwrapOrNull() != null) {
|
if (this.readAt?.isSome ?? false) {
|
||||||
json[r'readAt'] = this.readAt.unwrap().toUtc().toIso8601String();
|
json[r'readAt'] = this.readAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.readAt.isSome) {
|
if(this.readAt?.isNone ?? false) {
|
||||||
json[r'readAt'] = null;
|
json[r'readAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
22
mobile/openapi/lib/model/people_update_item.dart
generated
22
mobile/openapi/lib/model/people_update_item.dart
generated
@ -13,8 +13,8 @@ part of openapi.api;
|
|||||||
class PeopleUpdateItem {
|
class PeopleUpdateItem {
|
||||||
/// Returns a new [PeopleUpdateItem] instance.
|
/// Returns a new [PeopleUpdateItem] instance.
|
||||||
PeopleUpdateItem({
|
PeopleUpdateItem({
|
||||||
this.birthDate = const None(),
|
this.birthDate,
|
||||||
this.color = const None(),
|
this.color,
|
||||||
this.featureFaceAssetId,
|
this.featureFaceAssetId,
|
||||||
required this.id,
|
required this.id,
|
||||||
this.isFavorite,
|
this.isFavorite,
|
||||||
@ -23,9 +23,9 @@ class PeopleUpdateItem {
|
|||||||
});
|
});
|
||||||
|
|
||||||
/// Person date of birth. Note: the mobile app cannot currently set the birth date to null.
|
/// Person date of birth. Note: the mobile app cannot currently set the birth date to null.
|
||||||
Option<DateTime> birthDate;
|
Option<DateTime>? birthDate;
|
||||||
|
|
||||||
Option<String> color;
|
Option<String>? color;
|
||||||
|
|
||||||
/// Asset is used to get the feature face thumbnail.
|
/// Asset is used to get the feature face thumbnail.
|
||||||
///
|
///
|
||||||
@ -78,8 +78,8 @@ class PeopleUpdateItem {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(birthDate.hashCode) +
|
(birthDate == null ? 0 : birthDate!.hashCode) +
|
||||||
(color.hashCode) +
|
(color == null ? 0 : color!.hashCode) +
|
||||||
(featureFaceAssetId == null ? 0 : featureFaceAssetId!.hashCode) +
|
(featureFaceAssetId == null ? 0 : featureFaceAssetId!.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||||
@ -91,17 +91,17 @@ class PeopleUpdateItem {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.birthDate.unwrapOrNull() != null) {
|
if (this.birthDate?.isSome ?? false) {
|
||||||
json[r'birthDate'] = _dateFormatter.format(this.birthDate.unwrap().toUtc());
|
json[r'birthDate'] = _dateFormatter.format(this.birthDate!.unwrap().toUtc());
|
||||||
} else {
|
} else {
|
||||||
if(this.birthDate.isSome) {
|
if(this.birthDate?.isNone ?? false) {
|
||||||
json[r'birthDate'] = null;
|
json[r'birthDate'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.color.unwrapOrNull() != null) {
|
if (this.color?.isSome ?? false) {
|
||||||
json[r'color'] = this.color;
|
json[r'color'] = this.color;
|
||||||
} else {
|
} else {
|
||||||
if(this.color.isSome) {
|
if(this.color?.isNone ?? false) {
|
||||||
json[r'color'] = null;
|
json[r'color'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
22
mobile/openapi/lib/model/person_create_dto.dart
generated
22
mobile/openapi/lib/model/person_create_dto.dart
generated
@ -13,17 +13,17 @@ part of openapi.api;
|
|||||||
class PersonCreateDto {
|
class PersonCreateDto {
|
||||||
/// Returns a new [PersonCreateDto] instance.
|
/// Returns a new [PersonCreateDto] instance.
|
||||||
PersonCreateDto({
|
PersonCreateDto({
|
||||||
this.birthDate = const None(),
|
this.birthDate,
|
||||||
this.color = const None(),
|
this.color,
|
||||||
this.isFavorite,
|
this.isFavorite,
|
||||||
this.isHidden,
|
this.isHidden,
|
||||||
this.name,
|
this.name,
|
||||||
});
|
});
|
||||||
|
|
||||||
/// Person date of birth. Note: the mobile app cannot currently set the birth date to null.
|
/// Person date of birth. Note: the mobile app cannot currently set the birth date to null.
|
||||||
Option<DateTime> birthDate;
|
Option<DateTime>? birthDate;
|
||||||
|
|
||||||
Option<String> color;
|
Option<String>? color;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -62,8 +62,8 @@ class PersonCreateDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(birthDate.hashCode) +
|
(birthDate == null ? 0 : birthDate!.hashCode) +
|
||||||
(color.hashCode) +
|
(color == null ? 0 : color!.hashCode) +
|
||||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||||
(isHidden == null ? 0 : isHidden!.hashCode) +
|
(isHidden == null ? 0 : isHidden!.hashCode) +
|
||||||
(name == null ? 0 : name!.hashCode);
|
(name == null ? 0 : name!.hashCode);
|
||||||
@ -73,17 +73,17 @@ class PersonCreateDto {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.birthDate.unwrapOrNull() != null) {
|
if (this.birthDate?.isSome ?? false) {
|
||||||
json[r'birthDate'] = _dateFormatter.format(this.birthDate.unwrap().toUtc());
|
json[r'birthDate'] = _dateFormatter.format(this.birthDate!.unwrap().toUtc());
|
||||||
} else {
|
} else {
|
||||||
if(this.birthDate.isSome) {
|
if(this.birthDate?.isNone ?? false) {
|
||||||
json[r'birthDate'] = null;
|
json[r'birthDate'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.color.unwrapOrNull() != null) {
|
if (this.color?.isSome ?? false) {
|
||||||
json[r'color'] = this.color;
|
json[r'color'] = this.color;
|
||||||
} else {
|
} else {
|
||||||
if(this.color.isSome) {
|
if(this.color?.isNone ?? false) {
|
||||||
json[r'color'] = null;
|
json[r'color'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
12
mobile/openapi/lib/model/person_response_dto.dart
generated
12
mobile/openapi/lib/model/person_response_dto.dart
generated
@ -13,7 +13,7 @@ part of openapi.api;
|
|||||||
class PersonResponseDto {
|
class PersonResponseDto {
|
||||||
/// Returns a new [PersonResponseDto] instance.
|
/// Returns a new [PersonResponseDto] instance.
|
||||||
PersonResponseDto({
|
PersonResponseDto({
|
||||||
this.birthDate = const None(),
|
required this.birthDate,
|
||||||
this.color,
|
this.color,
|
||||||
required this.id,
|
required this.id,
|
||||||
this.isFavorite,
|
this.isFavorite,
|
||||||
@ -23,7 +23,7 @@ class PersonResponseDto {
|
|||||||
this.updatedAt,
|
this.updatedAt,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<DateTime> birthDate;
|
Option<DateTime>? birthDate;
|
||||||
|
|
||||||
/// This property was added in v1.126.0
|
/// This property was added in v1.126.0
|
||||||
///
|
///
|
||||||
@ -74,7 +74,7 @@ class PersonResponseDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(birthDate.hashCode) +
|
(birthDate == null ? 0 : birthDate!.hashCode) +
|
||||||
(color == null ? 0 : color!.hashCode) +
|
(color == null ? 0 : color!.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||||
@ -88,10 +88,10 @@ class PersonResponseDto {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.birthDate.unwrapOrNull() != null) {
|
if (this.birthDate?.isSome ?? false) {
|
||||||
json[r'birthDate'] = _dateFormatter.format(this.birthDate.unwrap().toUtc());
|
json[r'birthDate'] = _dateFormatter.format(this.birthDate!.unwrap().toUtc());
|
||||||
} else {
|
} else {
|
||||||
if(this.birthDate.isSome) {
|
if(this.birthDate?.isNone ?? false) {
|
||||||
json[r'birthDate'] = null;
|
json[r'birthDate'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
22
mobile/openapi/lib/model/person_update_dto.dart
generated
22
mobile/openapi/lib/model/person_update_dto.dart
generated
@ -13,8 +13,8 @@ part of openapi.api;
|
|||||||
class PersonUpdateDto {
|
class PersonUpdateDto {
|
||||||
/// Returns a new [PersonUpdateDto] instance.
|
/// Returns a new [PersonUpdateDto] instance.
|
||||||
PersonUpdateDto({
|
PersonUpdateDto({
|
||||||
this.birthDate = const None(),
|
this.birthDate,
|
||||||
this.color = const None(),
|
this.color,
|
||||||
this.featureFaceAssetId,
|
this.featureFaceAssetId,
|
||||||
this.isFavorite,
|
this.isFavorite,
|
||||||
this.isHidden,
|
this.isHidden,
|
||||||
@ -22,9 +22,9 @@ class PersonUpdateDto {
|
|||||||
});
|
});
|
||||||
|
|
||||||
/// Person date of birth. Note: the mobile app cannot currently set the birth date to null.
|
/// Person date of birth. Note: the mobile app cannot currently set the birth date to null.
|
||||||
Option<DateTime> birthDate;
|
Option<DateTime>? birthDate;
|
||||||
|
|
||||||
Option<String> color;
|
Option<String>? color;
|
||||||
|
|
||||||
/// Asset is used to get the feature face thumbnail.
|
/// Asset is used to get the feature face thumbnail.
|
||||||
///
|
///
|
||||||
@ -73,8 +73,8 @@ class PersonUpdateDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(birthDate.hashCode) +
|
(birthDate == null ? 0 : birthDate!.hashCode) +
|
||||||
(color.hashCode) +
|
(color == null ? 0 : color!.hashCode) +
|
||||||
(featureFaceAssetId == null ? 0 : featureFaceAssetId!.hashCode) +
|
(featureFaceAssetId == null ? 0 : featureFaceAssetId!.hashCode) +
|
||||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||||
(isHidden == null ? 0 : isHidden!.hashCode) +
|
(isHidden == null ? 0 : isHidden!.hashCode) +
|
||||||
@ -85,17 +85,17 @@ class PersonUpdateDto {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.birthDate.unwrapOrNull() != null) {
|
if (this.birthDate?.isSome ?? false) {
|
||||||
json[r'birthDate'] = _dateFormatter.format(this.birthDate.unwrap().toUtc());
|
json[r'birthDate'] = _dateFormatter.format(this.birthDate!.unwrap().toUtc());
|
||||||
} else {
|
} else {
|
||||||
if(this.birthDate.isSome) {
|
if(this.birthDate?.isNone ?? false) {
|
||||||
json[r'birthDate'] = null;
|
json[r'birthDate'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.color.unwrapOrNull() != null) {
|
if (this.color?.isSome ?? false) {
|
||||||
json[r'color'] = this.color;
|
json[r'color'] = this.color;
|
||||||
} else {
|
} else {
|
||||||
if(this.color.isSome) {
|
if(this.color?.isNone ?? false) {
|
||||||
json[r'color'] = null;
|
json[r'color'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,7 @@ part of openapi.api;
|
|||||||
class PersonWithFacesResponseDto {
|
class PersonWithFacesResponseDto {
|
||||||
/// Returns a new [PersonWithFacesResponseDto] instance.
|
/// Returns a new [PersonWithFacesResponseDto] instance.
|
||||||
PersonWithFacesResponseDto({
|
PersonWithFacesResponseDto({
|
||||||
this.birthDate = const None(),
|
required this.birthDate,
|
||||||
this.color,
|
this.color,
|
||||||
this.faces = const [],
|
this.faces = const [],
|
||||||
required this.id,
|
required this.id,
|
||||||
@ -24,7 +24,7 @@ class PersonWithFacesResponseDto {
|
|||||||
this.updatedAt,
|
this.updatedAt,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<DateTime> birthDate;
|
Option<DateTime>? birthDate;
|
||||||
|
|
||||||
/// This property was added in v1.126.0
|
/// This property was added in v1.126.0
|
||||||
///
|
///
|
||||||
@ -78,7 +78,7 @@ class PersonWithFacesResponseDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(birthDate.hashCode) +
|
(birthDate == null ? 0 : birthDate!.hashCode) +
|
||||||
(color == null ? 0 : color!.hashCode) +
|
(color == null ? 0 : color!.hashCode) +
|
||||||
(faces.hashCode) +
|
(faces.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
@ -93,10 +93,10 @@ class PersonWithFacesResponseDto {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.birthDate.unwrapOrNull() != null) {
|
if (this.birthDate?.isSome ?? false) {
|
||||||
json[r'birthDate'] = _dateFormatter.format(this.birthDate.unwrap().toUtc());
|
json[r'birthDate'] = _dateFormatter.format(this.birthDate!.unwrap().toUtc());
|
||||||
} else {
|
} else {
|
||||||
if(this.birthDate.isSome) {
|
if(this.birthDate?.isNone ?? false) {
|
||||||
json[r'birthDate'] = null;
|
json[r'birthDate'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
60
mobile/openapi/lib/model/random_search_dto.dart
generated
60
mobile/openapi/lib/model/random_search_dto.dart
generated
@ -13,8 +13,8 @@ part of openapi.api;
|
|||||||
class RandomSearchDto {
|
class RandomSearchDto {
|
||||||
/// Returns a new [RandomSearchDto] instance.
|
/// Returns a new [RandomSearchDto] instance.
|
||||||
RandomSearchDto({
|
RandomSearchDto({
|
||||||
this.city = const None(),
|
this.city,
|
||||||
this.country = const None(),
|
this.country,
|
||||||
this.createdAfter,
|
this.createdAfter,
|
||||||
this.createdBefore,
|
this.createdBefore,
|
||||||
this.deviceId,
|
this.deviceId,
|
||||||
@ -23,14 +23,14 @@ class RandomSearchDto {
|
|||||||
this.isMotion,
|
this.isMotion,
|
||||||
this.isNotInAlbum,
|
this.isNotInAlbum,
|
||||||
this.isOffline,
|
this.isOffline,
|
||||||
this.lensModel = const None(),
|
this.lensModel,
|
||||||
this.libraryId = const None(),
|
this.libraryId,
|
||||||
this.make,
|
this.make,
|
||||||
this.model = const None(),
|
this.model,
|
||||||
this.personIds = const [],
|
this.personIds = const [],
|
||||||
this.rating,
|
this.rating,
|
||||||
this.size,
|
this.size,
|
||||||
this.state = const None(),
|
this.state,
|
||||||
this.tagIds = const [],
|
this.tagIds = const [],
|
||||||
this.takenAfter,
|
this.takenAfter,
|
||||||
this.takenBefore,
|
this.takenBefore,
|
||||||
@ -46,9 +46,9 @@ class RandomSearchDto {
|
|||||||
this.withStacked,
|
this.withStacked,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<String> city;
|
Option<String>? city;
|
||||||
|
|
||||||
Option<String> country;
|
Option<String>? country;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -114,9 +114,9 @@ class RandomSearchDto {
|
|||||||
///
|
///
|
||||||
bool? isOffline;
|
bool? isOffline;
|
||||||
|
|
||||||
Option<String> lensModel;
|
Option<String>? lensModel;
|
||||||
|
|
||||||
Option<String> libraryId;
|
Option<String>? libraryId;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -126,7 +126,7 @@ class RandomSearchDto {
|
|||||||
///
|
///
|
||||||
String? make;
|
String? make;
|
||||||
|
|
||||||
Option<String> model;
|
Option<String>? model;
|
||||||
|
|
||||||
List<String> personIds;
|
List<String> personIds;
|
||||||
|
|
||||||
@ -150,7 +150,7 @@ class RandomSearchDto {
|
|||||||
///
|
///
|
||||||
num? size;
|
num? size;
|
||||||
|
|
||||||
Option<String> state;
|
Option<String>? state;
|
||||||
|
|
||||||
List<String> tagIds;
|
List<String> tagIds;
|
||||||
|
|
||||||
@ -287,8 +287,8 @@ class RandomSearchDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(city.hashCode) +
|
(city == null ? 0 : city!.hashCode) +
|
||||||
(country.hashCode) +
|
(country == null ? 0 : country!.hashCode) +
|
||||||
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
||||||
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
||||||
(deviceId == null ? 0 : deviceId!.hashCode) +
|
(deviceId == null ? 0 : deviceId!.hashCode) +
|
||||||
@ -297,14 +297,14 @@ class RandomSearchDto {
|
|||||||
(isMotion == null ? 0 : isMotion!.hashCode) +
|
(isMotion == null ? 0 : isMotion!.hashCode) +
|
||||||
(isNotInAlbum == null ? 0 : isNotInAlbum!.hashCode) +
|
(isNotInAlbum == null ? 0 : isNotInAlbum!.hashCode) +
|
||||||
(isOffline == null ? 0 : isOffline!.hashCode) +
|
(isOffline == null ? 0 : isOffline!.hashCode) +
|
||||||
(lensModel.hashCode) +
|
(lensModel == null ? 0 : lensModel!.hashCode) +
|
||||||
(libraryId.hashCode) +
|
(libraryId == null ? 0 : libraryId!.hashCode) +
|
||||||
(make == null ? 0 : make!.hashCode) +
|
(make == null ? 0 : make!.hashCode) +
|
||||||
(model.hashCode) +
|
(model == null ? 0 : model!.hashCode) +
|
||||||
(personIds.hashCode) +
|
(personIds.hashCode) +
|
||||||
(rating == null ? 0 : rating!.hashCode) +
|
(rating == null ? 0 : rating!.hashCode) +
|
||||||
(size == null ? 0 : size!.hashCode) +
|
(size == null ? 0 : size!.hashCode) +
|
||||||
(state.hashCode) +
|
(state == null ? 0 : state!.hashCode) +
|
||||||
(tagIds.hashCode) +
|
(tagIds.hashCode) +
|
||||||
(takenAfter == null ? 0 : takenAfter!.hashCode) +
|
(takenAfter == null ? 0 : takenAfter!.hashCode) +
|
||||||
(takenBefore == null ? 0 : takenBefore!.hashCode) +
|
(takenBefore == null ? 0 : takenBefore!.hashCode) +
|
||||||
@ -324,17 +324,17 @@ class RandomSearchDto {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.city.unwrapOrNull() != null) {
|
if (this.city?.isSome ?? false) {
|
||||||
json[r'city'] = this.city;
|
json[r'city'] = this.city;
|
||||||
} else {
|
} else {
|
||||||
if(this.city.isSome) {
|
if(this.city?.isNone ?? false) {
|
||||||
json[r'city'] = null;
|
json[r'city'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.country.unwrapOrNull() != null) {
|
if (this.country?.isSome ?? false) {
|
||||||
json[r'country'] = this.country;
|
json[r'country'] = this.country;
|
||||||
} else {
|
} else {
|
||||||
if(this.country.isSome) {
|
if(this.country?.isNone ?? false) {
|
||||||
json[r'country'] = null;
|
json[r'country'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -378,17 +378,17 @@ class RandomSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'isOffline'] = null;
|
// json[r'isOffline'] = null;
|
||||||
}
|
}
|
||||||
if (this.lensModel.unwrapOrNull() != null) {
|
if (this.lensModel?.isSome ?? false) {
|
||||||
json[r'lensModel'] = this.lensModel;
|
json[r'lensModel'] = this.lensModel;
|
||||||
} else {
|
} else {
|
||||||
if(this.lensModel.isSome) {
|
if(this.lensModel?.isNone ?? false) {
|
||||||
json[r'lensModel'] = null;
|
json[r'lensModel'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.libraryId.unwrapOrNull() != null) {
|
if (this.libraryId?.isSome ?? false) {
|
||||||
json[r'libraryId'] = this.libraryId;
|
json[r'libraryId'] = this.libraryId;
|
||||||
} else {
|
} else {
|
||||||
if(this.libraryId.isSome) {
|
if(this.libraryId?.isNone ?? false) {
|
||||||
json[r'libraryId'] = null;
|
json[r'libraryId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -397,10 +397,10 @@ class RandomSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'make'] = null;
|
// json[r'make'] = null;
|
||||||
}
|
}
|
||||||
if (this.model.unwrapOrNull() != null) {
|
if (this.model?.isSome ?? false) {
|
||||||
json[r'model'] = this.model;
|
json[r'model'] = this.model;
|
||||||
} else {
|
} else {
|
||||||
if(this.model.isSome) {
|
if(this.model?.isNone ?? false) {
|
||||||
json[r'model'] = null;
|
json[r'model'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -415,10 +415,10 @@ class RandomSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'size'] = null;
|
// json[r'size'] = null;
|
||||||
}
|
}
|
||||||
if (this.state.unwrapOrNull() != null) {
|
if (this.state?.isSome ?? false) {
|
||||||
json[r'state'] = this.state;
|
json[r'state'] = this.state;
|
||||||
} else {
|
} else {
|
||||||
if(this.state.isSome) {
|
if(this.state?.isNone ?? false) {
|
||||||
json[r'state'] = null;
|
json[r'state'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,13 +13,13 @@ part of openapi.api;
|
|||||||
class ReverseGeocodingStateResponseDto {
|
class ReverseGeocodingStateResponseDto {
|
||||||
/// Returns a new [ReverseGeocodingStateResponseDto] instance.
|
/// Returns a new [ReverseGeocodingStateResponseDto] instance.
|
||||||
ReverseGeocodingStateResponseDto({
|
ReverseGeocodingStateResponseDto({
|
||||||
this.lastImportFileName = const None(),
|
required this.lastImportFileName,
|
||||||
this.lastUpdate = const None(),
|
required this.lastUpdate,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<String> lastImportFileName;
|
Option<String>? lastImportFileName;
|
||||||
|
|
||||||
Option<String> lastUpdate;
|
Option<String>? lastUpdate;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is ReverseGeocodingStateResponseDto &&
|
bool operator ==(Object other) => identical(this, other) || other is ReverseGeocodingStateResponseDto &&
|
||||||
@ -29,25 +29,25 @@ class ReverseGeocodingStateResponseDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(lastImportFileName.hashCode) +
|
(lastImportFileName == null ? 0 : lastImportFileName!.hashCode) +
|
||||||
(lastUpdate.hashCode);
|
(lastUpdate == null ? 0 : lastUpdate!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'ReverseGeocodingStateResponseDto[lastImportFileName=$lastImportFileName, lastUpdate=$lastUpdate]';
|
String toString() => 'ReverseGeocodingStateResponseDto[lastImportFileName=$lastImportFileName, lastUpdate=$lastUpdate]';
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.lastImportFileName.unwrapOrNull() != null) {
|
if (this.lastImportFileName?.isSome ?? false) {
|
||||||
json[r'lastImportFileName'] = this.lastImportFileName;
|
json[r'lastImportFileName'] = this.lastImportFileName;
|
||||||
} else {
|
} else {
|
||||||
if(this.lastImportFileName.isSome) {
|
if(this.lastImportFileName?.isNone ?? false) {
|
||||||
json[r'lastImportFileName'] = null;
|
json[r'lastImportFileName'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.lastUpdate.unwrapOrNull() != null) {
|
if (this.lastUpdate?.isSome ?? false) {
|
||||||
json[r'lastUpdate'] = this.lastUpdate;
|
json[r'lastUpdate'] = this.lastUpdate;
|
||||||
} else {
|
} else {
|
||||||
if(this.lastUpdate.isSome) {
|
if(this.lastUpdate?.isNone ?? false) {
|
||||||
json[r'lastUpdate'] = null;
|
json[r'lastUpdate'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,7 @@ class SearchAssetResponseDto {
|
|||||||
required this.count,
|
required this.count,
|
||||||
this.facets = const [],
|
this.facets = const [],
|
||||||
this.items = const [],
|
this.items = const [],
|
||||||
this.nextPage = const None(),
|
required this.nextPage,
|
||||||
required this.total,
|
required this.total,
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -26,7 +26,7 @@ class SearchAssetResponseDto {
|
|||||||
|
|
||||||
List<AssetResponseDto> items;
|
List<AssetResponseDto> items;
|
||||||
|
|
||||||
Option<String> nextPage;
|
Option<String>? nextPage;
|
||||||
|
|
||||||
int total;
|
int total;
|
||||||
|
|
||||||
@ -44,7 +44,7 @@ class SearchAssetResponseDto {
|
|||||||
(count.hashCode) +
|
(count.hashCode) +
|
||||||
(facets.hashCode) +
|
(facets.hashCode) +
|
||||||
(items.hashCode) +
|
(items.hashCode) +
|
||||||
(nextPage.hashCode) +
|
(nextPage == null ? 0 : nextPage!.hashCode) +
|
||||||
(total.hashCode);
|
(total.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@ -55,10 +55,10 @@ class SearchAssetResponseDto {
|
|||||||
json[r'count'] = this.count;
|
json[r'count'] = this.count;
|
||||||
json[r'facets'] = this.facets;
|
json[r'facets'] = this.facets;
|
||||||
json[r'items'] = this.items;
|
json[r'items'] = this.items;
|
||||||
if (this.nextPage.unwrapOrNull() != null) {
|
if (this.nextPage?.isSome ?? false) {
|
||||||
json[r'nextPage'] = this.nextPage;
|
json[r'nextPage'] = this.nextPage;
|
||||||
} else {
|
} else {
|
||||||
if(this.nextPage.isSome) {
|
if(this.nextPage?.isNone ?? false) {
|
||||||
json[r'nextPage'] = null;
|
json[r'nextPage'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
12
mobile/openapi/lib/model/shared_link_create_dto.dart
generated
12
mobile/openapi/lib/model/shared_link_create_dto.dart
generated
@ -18,7 +18,7 @@ class SharedLinkCreateDto {
|
|||||||
this.allowUpload,
|
this.allowUpload,
|
||||||
this.assetIds = const [],
|
this.assetIds = const [],
|
||||||
this.description,
|
this.description,
|
||||||
this.expiresAt = const None(),
|
this.expiresAt,
|
||||||
this.password,
|
this.password,
|
||||||
this.showMetadata = true,
|
this.showMetadata = true,
|
||||||
required this.type,
|
required this.type,
|
||||||
@ -52,7 +52,7 @@ class SharedLinkCreateDto {
|
|||||||
///
|
///
|
||||||
String? description;
|
String? description;
|
||||||
|
|
||||||
Option<DateTime> expiresAt;
|
Option<DateTime>? expiresAt;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -86,7 +86,7 @@ class SharedLinkCreateDto {
|
|||||||
(allowUpload == null ? 0 : allowUpload!.hashCode) +
|
(allowUpload == null ? 0 : allowUpload!.hashCode) +
|
||||||
(assetIds.hashCode) +
|
(assetIds.hashCode) +
|
||||||
(description == null ? 0 : description!.hashCode) +
|
(description == null ? 0 : description!.hashCode) +
|
||||||
(expiresAt.hashCode) +
|
(expiresAt == null ? 0 : expiresAt!.hashCode) +
|
||||||
(password == null ? 0 : password!.hashCode) +
|
(password == null ? 0 : password!.hashCode) +
|
||||||
(showMetadata.hashCode) +
|
(showMetadata.hashCode) +
|
||||||
(type.hashCode);
|
(type.hashCode);
|
||||||
@ -113,10 +113,10 @@ class SharedLinkCreateDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'description'] = null;
|
// json[r'description'] = null;
|
||||||
}
|
}
|
||||||
if (this.expiresAt.unwrapOrNull() != null) {
|
if (this.expiresAt?.isSome ?? false) {
|
||||||
json[r'expiresAt'] = this.expiresAt.unwrap().toUtc().toIso8601String();
|
json[r'expiresAt'] = this.expiresAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.expiresAt.isSome) {
|
if(this.expiresAt?.isNone ?? false) {
|
||||||
json[r'expiresAt'] = null;
|
json[r'expiresAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
12
mobile/openapi/lib/model/shared_link_edit_dto.dart
generated
12
mobile/openapi/lib/model/shared_link_edit_dto.dart
generated
@ -17,7 +17,7 @@ class SharedLinkEditDto {
|
|||||||
this.allowUpload,
|
this.allowUpload,
|
||||||
this.changeExpiryTime,
|
this.changeExpiryTime,
|
||||||
this.description,
|
this.description,
|
||||||
this.expiresAt = const None(),
|
this.expiresAt,
|
||||||
this.password,
|
this.password,
|
||||||
this.showMetadata,
|
this.showMetadata,
|
||||||
});
|
});
|
||||||
@ -55,7 +55,7 @@ class SharedLinkEditDto {
|
|||||||
///
|
///
|
||||||
String? description;
|
String? description;
|
||||||
|
|
||||||
Option<DateTime> expiresAt;
|
Option<DateTime>? expiresAt;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -90,7 +90,7 @@ class SharedLinkEditDto {
|
|||||||
(allowUpload == null ? 0 : allowUpload!.hashCode) +
|
(allowUpload == null ? 0 : allowUpload!.hashCode) +
|
||||||
(changeExpiryTime == null ? 0 : changeExpiryTime!.hashCode) +
|
(changeExpiryTime == null ? 0 : changeExpiryTime!.hashCode) +
|
||||||
(description == null ? 0 : description!.hashCode) +
|
(description == null ? 0 : description!.hashCode) +
|
||||||
(expiresAt.hashCode) +
|
(expiresAt == null ? 0 : expiresAt!.hashCode) +
|
||||||
(password == null ? 0 : password!.hashCode) +
|
(password == null ? 0 : password!.hashCode) +
|
||||||
(showMetadata == null ? 0 : showMetadata!.hashCode);
|
(showMetadata == null ? 0 : showMetadata!.hashCode);
|
||||||
|
|
||||||
@ -119,10 +119,10 @@ class SharedLinkEditDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'description'] = null;
|
// json[r'description'] = null;
|
||||||
}
|
}
|
||||||
if (this.expiresAt.unwrapOrNull() != null) {
|
if (this.expiresAt?.isSome ?? false) {
|
||||||
json[r'expiresAt'] = this.expiresAt.unwrap().toUtc().toIso8601String();
|
json[r'expiresAt'] = this.expiresAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.expiresAt.isSome) {
|
if(this.expiresAt?.isNone ?? false) {
|
||||||
json[r'expiresAt'] = null;
|
json[r'expiresAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -18,13 +18,13 @@ class SharedLinkResponseDto {
|
|||||||
required this.allowUpload,
|
required this.allowUpload,
|
||||||
this.assets = const [],
|
this.assets = const [],
|
||||||
required this.createdAt,
|
required this.createdAt,
|
||||||
this.description = const None(),
|
required this.description,
|
||||||
this.expiresAt = const None(),
|
required this.expiresAt,
|
||||||
required this.id,
|
required this.id,
|
||||||
required this.key,
|
required this.key,
|
||||||
this.password = const None(),
|
required this.password,
|
||||||
required this.showMetadata,
|
required this.showMetadata,
|
||||||
this.token = const None(),
|
this.token,
|
||||||
required this.type,
|
required this.type,
|
||||||
required this.userId,
|
required this.userId,
|
||||||
});
|
});
|
||||||
@ -45,19 +45,19 @@ class SharedLinkResponseDto {
|
|||||||
|
|
||||||
DateTime createdAt;
|
DateTime createdAt;
|
||||||
|
|
||||||
Option<String> description;
|
Option<String>? description;
|
||||||
|
|
||||||
Option<DateTime> expiresAt;
|
Option<DateTime>? expiresAt;
|
||||||
|
|
||||||
String id;
|
String id;
|
||||||
|
|
||||||
String key;
|
String key;
|
||||||
|
|
||||||
Option<String> password;
|
Option<String>? password;
|
||||||
|
|
||||||
bool showMetadata;
|
bool showMetadata;
|
||||||
|
|
||||||
Option<String> token;
|
Option<String>? token;
|
||||||
|
|
||||||
SharedLinkType type;
|
SharedLinkType type;
|
||||||
|
|
||||||
@ -88,13 +88,13 @@ class SharedLinkResponseDto {
|
|||||||
(allowUpload.hashCode) +
|
(allowUpload.hashCode) +
|
||||||
(assets.hashCode) +
|
(assets.hashCode) +
|
||||||
(createdAt.hashCode) +
|
(createdAt.hashCode) +
|
||||||
(description.hashCode) +
|
(description == null ? 0 : description!.hashCode) +
|
||||||
(expiresAt.hashCode) +
|
(expiresAt == null ? 0 : expiresAt!.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(key.hashCode) +
|
(key.hashCode) +
|
||||||
(password.hashCode) +
|
(password == null ? 0 : password!.hashCode) +
|
||||||
(showMetadata.hashCode) +
|
(showMetadata.hashCode) +
|
||||||
(token.hashCode) +
|
(token == null ? 0 : token!.hashCode) +
|
||||||
(type.hashCode) +
|
(type.hashCode) +
|
||||||
(userId.hashCode);
|
(userId.hashCode);
|
||||||
|
|
||||||
@ -112,34 +112,34 @@ class SharedLinkResponseDto {
|
|||||||
json[r'allowUpload'] = this.allowUpload;
|
json[r'allowUpload'] = this.allowUpload;
|
||||||
json[r'assets'] = this.assets;
|
json[r'assets'] = this.assets;
|
||||||
json[r'createdAt'] = this.createdAt.toUtc().toIso8601String();
|
json[r'createdAt'] = this.createdAt.toUtc().toIso8601String();
|
||||||
if (this.description.unwrapOrNull() != null) {
|
if (this.description?.isSome ?? false) {
|
||||||
json[r'description'] = this.description;
|
json[r'description'] = this.description;
|
||||||
} else {
|
} else {
|
||||||
if(this.description.isSome) {
|
if(this.description?.isNone ?? false) {
|
||||||
json[r'description'] = null;
|
json[r'description'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.expiresAt.unwrapOrNull() != null) {
|
if (this.expiresAt?.isSome ?? false) {
|
||||||
json[r'expiresAt'] = this.expiresAt.unwrap().toUtc().toIso8601String();
|
json[r'expiresAt'] = this.expiresAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.expiresAt.isSome) {
|
if(this.expiresAt?.isNone ?? false) {
|
||||||
json[r'expiresAt'] = null;
|
json[r'expiresAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
json[r'id'] = this.id;
|
json[r'id'] = this.id;
|
||||||
json[r'key'] = this.key;
|
json[r'key'] = this.key;
|
||||||
if (this.password.unwrapOrNull() != null) {
|
if (this.password?.isSome ?? false) {
|
||||||
json[r'password'] = this.password;
|
json[r'password'] = this.password;
|
||||||
} else {
|
} else {
|
||||||
if(this.password.isSome) {
|
if(this.password?.isNone ?? false) {
|
||||||
json[r'password'] = null;
|
json[r'password'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
json[r'showMetadata'] = this.showMetadata;
|
json[r'showMetadata'] = this.showMetadata;
|
||||||
if (this.token.unwrapOrNull() != null) {
|
if (this.token?.isSome ?? false) {
|
||||||
json[r'token'] = this.token;
|
json[r'token'] = this.token;
|
||||||
} else {
|
} else {
|
||||||
if(this.token.isSome) {
|
if(this.token?.isNone ?? false) {
|
||||||
json[r'token'] = null;
|
json[r'token'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
60
mobile/openapi/lib/model/smart_search_dto.dart
generated
60
mobile/openapi/lib/model/smart_search_dto.dart
generated
@ -13,8 +13,8 @@ part of openapi.api;
|
|||||||
class SmartSearchDto {
|
class SmartSearchDto {
|
||||||
/// Returns a new [SmartSearchDto] instance.
|
/// Returns a new [SmartSearchDto] instance.
|
||||||
SmartSearchDto({
|
SmartSearchDto({
|
||||||
this.city = const None(),
|
this.city,
|
||||||
this.country = const None(),
|
this.country,
|
||||||
this.createdAfter,
|
this.createdAfter,
|
||||||
this.createdBefore,
|
this.createdBefore,
|
||||||
this.deviceId,
|
this.deviceId,
|
||||||
@ -24,16 +24,16 @@ class SmartSearchDto {
|
|||||||
this.isNotInAlbum,
|
this.isNotInAlbum,
|
||||||
this.isOffline,
|
this.isOffline,
|
||||||
this.language,
|
this.language,
|
||||||
this.lensModel = const None(),
|
this.lensModel,
|
||||||
this.libraryId = const None(),
|
this.libraryId,
|
||||||
this.make,
|
this.make,
|
||||||
this.model = const None(),
|
this.model,
|
||||||
this.page,
|
this.page,
|
||||||
this.personIds = const [],
|
this.personIds = const [],
|
||||||
required this.query,
|
required this.query,
|
||||||
this.rating,
|
this.rating,
|
||||||
this.size,
|
this.size,
|
||||||
this.state = const None(),
|
this.state,
|
||||||
this.tagIds = const [],
|
this.tagIds = const [],
|
||||||
this.takenAfter,
|
this.takenAfter,
|
||||||
this.takenBefore,
|
this.takenBefore,
|
||||||
@ -47,9 +47,9 @@ class SmartSearchDto {
|
|||||||
this.withExif,
|
this.withExif,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<String> city;
|
Option<String>? city;
|
||||||
|
|
||||||
Option<String> country;
|
Option<String>? country;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -123,9 +123,9 @@ class SmartSearchDto {
|
|||||||
///
|
///
|
||||||
String? language;
|
String? language;
|
||||||
|
|
||||||
Option<String> lensModel;
|
Option<String>? lensModel;
|
||||||
|
|
||||||
Option<String> libraryId;
|
Option<String>? libraryId;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -135,7 +135,7 @@ class SmartSearchDto {
|
|||||||
///
|
///
|
||||||
String? make;
|
String? make;
|
||||||
|
|
||||||
Option<String> model;
|
Option<String>? model;
|
||||||
|
|
||||||
/// Minimum value: 1
|
/// Minimum value: 1
|
||||||
///
|
///
|
||||||
@ -170,7 +170,7 @@ class SmartSearchDto {
|
|||||||
///
|
///
|
||||||
num? size;
|
num? size;
|
||||||
|
|
||||||
Option<String> state;
|
Option<String>? state;
|
||||||
|
|
||||||
List<String> tagIds;
|
List<String> tagIds;
|
||||||
|
|
||||||
@ -292,8 +292,8 @@ class SmartSearchDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(city.hashCode) +
|
(city == null ? 0 : city!.hashCode) +
|
||||||
(country.hashCode) +
|
(country == null ? 0 : country!.hashCode) +
|
||||||
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
(createdAfter == null ? 0 : createdAfter!.hashCode) +
|
||||||
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
(createdBefore == null ? 0 : createdBefore!.hashCode) +
|
||||||
(deviceId == null ? 0 : deviceId!.hashCode) +
|
(deviceId == null ? 0 : deviceId!.hashCode) +
|
||||||
@ -303,16 +303,16 @@ class SmartSearchDto {
|
|||||||
(isNotInAlbum == null ? 0 : isNotInAlbum!.hashCode) +
|
(isNotInAlbum == null ? 0 : isNotInAlbum!.hashCode) +
|
||||||
(isOffline == null ? 0 : isOffline!.hashCode) +
|
(isOffline == null ? 0 : isOffline!.hashCode) +
|
||||||
(language == null ? 0 : language!.hashCode) +
|
(language == null ? 0 : language!.hashCode) +
|
||||||
(lensModel.hashCode) +
|
(lensModel == null ? 0 : lensModel!.hashCode) +
|
||||||
(libraryId.hashCode) +
|
(libraryId == null ? 0 : libraryId!.hashCode) +
|
||||||
(make == null ? 0 : make!.hashCode) +
|
(make == null ? 0 : make!.hashCode) +
|
||||||
(model.hashCode) +
|
(model == null ? 0 : model!.hashCode) +
|
||||||
(page == null ? 0 : page!.hashCode) +
|
(page == null ? 0 : page!.hashCode) +
|
||||||
(personIds.hashCode) +
|
(personIds.hashCode) +
|
||||||
(query.hashCode) +
|
(query.hashCode) +
|
||||||
(rating == null ? 0 : rating!.hashCode) +
|
(rating == null ? 0 : rating!.hashCode) +
|
||||||
(size == null ? 0 : size!.hashCode) +
|
(size == null ? 0 : size!.hashCode) +
|
||||||
(state.hashCode) +
|
(state == null ? 0 : state!.hashCode) +
|
||||||
(tagIds.hashCode) +
|
(tagIds.hashCode) +
|
||||||
(takenAfter == null ? 0 : takenAfter!.hashCode) +
|
(takenAfter == null ? 0 : takenAfter!.hashCode) +
|
||||||
(takenBefore == null ? 0 : takenBefore!.hashCode) +
|
(takenBefore == null ? 0 : takenBefore!.hashCode) +
|
||||||
@ -330,17 +330,17 @@ class SmartSearchDto {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.city.unwrapOrNull() != null) {
|
if (this.city?.isSome ?? false) {
|
||||||
json[r'city'] = this.city;
|
json[r'city'] = this.city;
|
||||||
} else {
|
} else {
|
||||||
if(this.city.isSome) {
|
if(this.city?.isNone ?? false) {
|
||||||
json[r'city'] = null;
|
json[r'city'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.country.unwrapOrNull() != null) {
|
if (this.country?.isSome ?? false) {
|
||||||
json[r'country'] = this.country;
|
json[r'country'] = this.country;
|
||||||
} else {
|
} else {
|
||||||
if(this.country.isSome) {
|
if(this.country?.isNone ?? false) {
|
||||||
json[r'country'] = null;
|
json[r'country'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -389,17 +389,17 @@ class SmartSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'language'] = null;
|
// json[r'language'] = null;
|
||||||
}
|
}
|
||||||
if (this.lensModel.unwrapOrNull() != null) {
|
if (this.lensModel?.isSome ?? false) {
|
||||||
json[r'lensModel'] = this.lensModel;
|
json[r'lensModel'] = this.lensModel;
|
||||||
} else {
|
} else {
|
||||||
if(this.lensModel.isSome) {
|
if(this.lensModel?.isNone ?? false) {
|
||||||
json[r'lensModel'] = null;
|
json[r'lensModel'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.libraryId.unwrapOrNull() != null) {
|
if (this.libraryId?.isSome ?? false) {
|
||||||
json[r'libraryId'] = this.libraryId;
|
json[r'libraryId'] = this.libraryId;
|
||||||
} else {
|
} else {
|
||||||
if(this.libraryId.isSome) {
|
if(this.libraryId?.isNone ?? false) {
|
||||||
json[r'libraryId'] = null;
|
json[r'libraryId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -408,10 +408,10 @@ class SmartSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'make'] = null;
|
// json[r'make'] = null;
|
||||||
}
|
}
|
||||||
if (this.model.unwrapOrNull() != null) {
|
if (this.model?.isSome ?? false) {
|
||||||
json[r'model'] = this.model;
|
json[r'model'] = this.model;
|
||||||
} else {
|
} else {
|
||||||
if(this.model.isSome) {
|
if(this.model?.isNone ?? false) {
|
||||||
json[r'model'] = null;
|
json[r'model'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -432,10 +432,10 @@ class SmartSearchDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'size'] = null;
|
// json[r'size'] = null;
|
||||||
}
|
}
|
||||||
if (this.state.unwrapOrNull() != null) {
|
if (this.state?.isSome ?? false) {
|
||||||
json[r'state'] = this.state;
|
json[r'state'] = this.state;
|
||||||
} else {
|
} else {
|
||||||
if(this.state.isSome) {
|
if(this.state?.isNone ?? false) {
|
||||||
json[r'state'] = null;
|
json[r'state'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
244
mobile/openapi/lib/model/sync_asset_exif_v1.dart
generated
244
mobile/openapi/lib/model/sync_asset_exif_v1.dart
generated
@ -14,81 +14,81 @@ class SyncAssetExifV1 {
|
|||||||
/// Returns a new [SyncAssetExifV1] instance.
|
/// Returns a new [SyncAssetExifV1] instance.
|
||||||
SyncAssetExifV1({
|
SyncAssetExifV1({
|
||||||
required this.assetId,
|
required this.assetId,
|
||||||
this.city = const None(),
|
required this.city,
|
||||||
this.country = const None(),
|
required this.country,
|
||||||
this.dateTimeOriginal = const None(),
|
required this.dateTimeOriginal,
|
||||||
this.description = const None(),
|
required this.description,
|
||||||
this.exifImageHeight = const None(),
|
required this.exifImageHeight,
|
||||||
this.exifImageWidth = const None(),
|
required this.exifImageWidth,
|
||||||
this.exposureTime = const None(),
|
required this.exposureTime,
|
||||||
this.fNumber = const None(),
|
required this.fNumber,
|
||||||
this.fileSizeInByte = const None(),
|
required this.fileSizeInByte,
|
||||||
this.focalLength = const None(),
|
required this.focalLength,
|
||||||
this.fps = const None(),
|
required this.fps,
|
||||||
this.iso = const None(),
|
required this.iso,
|
||||||
this.latitude = const None(),
|
required this.latitude,
|
||||||
this.lensModel = const None(),
|
required this.lensModel,
|
||||||
this.longitude = const None(),
|
required this.longitude,
|
||||||
this.make = const None(),
|
required this.make,
|
||||||
this.model = const None(),
|
required this.model,
|
||||||
this.modifyDate = const None(),
|
required this.modifyDate,
|
||||||
this.orientation = const None(),
|
required this.orientation,
|
||||||
this.profileDescription = const None(),
|
required this.profileDescription,
|
||||||
this.projectionType = const None(),
|
required this.projectionType,
|
||||||
this.rating = const None(),
|
required this.rating,
|
||||||
this.state = const None(),
|
required this.state,
|
||||||
this.timeZone = const None(),
|
required this.timeZone,
|
||||||
});
|
});
|
||||||
|
|
||||||
String assetId;
|
String assetId;
|
||||||
|
|
||||||
Option<String> city;
|
Option<String>? city;
|
||||||
|
|
||||||
Option<String> country;
|
Option<String>? country;
|
||||||
|
|
||||||
Option<DateTime> dateTimeOriginal;
|
Option<DateTime>? dateTimeOriginal;
|
||||||
|
|
||||||
Option<String> description;
|
Option<String>? description;
|
||||||
|
|
||||||
Option<int> exifImageHeight;
|
Option<int>? exifImageHeight;
|
||||||
|
|
||||||
Option<int> exifImageWidth;
|
Option<int>? exifImageWidth;
|
||||||
|
|
||||||
Option<String> exposureTime;
|
Option<String>? exposureTime;
|
||||||
|
|
||||||
Option<int> fNumber;
|
Option<int>? fNumber;
|
||||||
|
|
||||||
Option<int> fileSizeInByte;
|
Option<int>? fileSizeInByte;
|
||||||
|
|
||||||
Option<int> focalLength;
|
Option<int>? focalLength;
|
||||||
|
|
||||||
Option<int> fps;
|
Option<int>? fps;
|
||||||
|
|
||||||
Option<int> iso;
|
Option<int>? iso;
|
||||||
|
|
||||||
Option<int> latitude;
|
Option<int>? latitude;
|
||||||
|
|
||||||
Option<String> lensModel;
|
Option<String>? lensModel;
|
||||||
|
|
||||||
Option<int> longitude;
|
Option<int>? longitude;
|
||||||
|
|
||||||
Option<String> make;
|
Option<String>? make;
|
||||||
|
|
||||||
Option<String> model;
|
Option<String>? model;
|
||||||
|
|
||||||
Option<DateTime> modifyDate;
|
Option<DateTime>? modifyDate;
|
||||||
|
|
||||||
Option<String> orientation;
|
Option<String>? orientation;
|
||||||
|
|
||||||
Option<String> profileDescription;
|
Option<String>? profileDescription;
|
||||||
|
|
||||||
Option<String> projectionType;
|
Option<String>? projectionType;
|
||||||
|
|
||||||
Option<int> rating;
|
Option<int>? rating;
|
||||||
|
|
||||||
Option<String> state;
|
Option<String>? state;
|
||||||
|
|
||||||
Option<String> timeZone;
|
Option<String>? timeZone;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is SyncAssetExifV1 &&
|
bool operator ==(Object other) => identical(this, other) || other is SyncAssetExifV1 &&
|
||||||
@ -122,30 +122,30 @@ class SyncAssetExifV1 {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(assetId.hashCode) +
|
(assetId.hashCode) +
|
||||||
(city.hashCode) +
|
(city == null ? 0 : city!.hashCode) +
|
||||||
(country.hashCode) +
|
(country == null ? 0 : country!.hashCode) +
|
||||||
(dateTimeOriginal.hashCode) +
|
(dateTimeOriginal == null ? 0 : dateTimeOriginal!.hashCode) +
|
||||||
(description.hashCode) +
|
(description == null ? 0 : description!.hashCode) +
|
||||||
(exifImageHeight.hashCode) +
|
(exifImageHeight == null ? 0 : exifImageHeight!.hashCode) +
|
||||||
(exifImageWidth.hashCode) +
|
(exifImageWidth == null ? 0 : exifImageWidth!.hashCode) +
|
||||||
(exposureTime.hashCode) +
|
(exposureTime == null ? 0 : exposureTime!.hashCode) +
|
||||||
(fNumber.hashCode) +
|
(fNumber == null ? 0 : fNumber!.hashCode) +
|
||||||
(fileSizeInByte.hashCode) +
|
(fileSizeInByte == null ? 0 : fileSizeInByte!.hashCode) +
|
||||||
(focalLength.hashCode) +
|
(focalLength == null ? 0 : focalLength!.hashCode) +
|
||||||
(fps.hashCode) +
|
(fps == null ? 0 : fps!.hashCode) +
|
||||||
(iso.hashCode) +
|
(iso == null ? 0 : iso!.hashCode) +
|
||||||
(latitude.hashCode) +
|
(latitude == null ? 0 : latitude!.hashCode) +
|
||||||
(lensModel.hashCode) +
|
(lensModel == null ? 0 : lensModel!.hashCode) +
|
||||||
(longitude.hashCode) +
|
(longitude == null ? 0 : longitude!.hashCode) +
|
||||||
(make.hashCode) +
|
(make == null ? 0 : make!.hashCode) +
|
||||||
(model.hashCode) +
|
(model == null ? 0 : model!.hashCode) +
|
||||||
(modifyDate.hashCode) +
|
(modifyDate == null ? 0 : modifyDate!.hashCode) +
|
||||||
(orientation.hashCode) +
|
(orientation == null ? 0 : orientation!.hashCode) +
|
||||||
(profileDescription.hashCode) +
|
(profileDescription == null ? 0 : profileDescription!.hashCode) +
|
||||||
(projectionType.hashCode) +
|
(projectionType == null ? 0 : projectionType!.hashCode) +
|
||||||
(rating.hashCode) +
|
(rating == null ? 0 : rating!.hashCode) +
|
||||||
(state.hashCode) +
|
(state == null ? 0 : state!.hashCode) +
|
||||||
(timeZone.hashCode);
|
(timeZone == null ? 0 : timeZone!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'SyncAssetExifV1[assetId=$assetId, city=$city, country=$country, dateTimeOriginal=$dateTimeOriginal, description=$description, exifImageHeight=$exifImageHeight, exifImageWidth=$exifImageWidth, exposureTime=$exposureTime, fNumber=$fNumber, fileSizeInByte=$fileSizeInByte, focalLength=$focalLength, fps=$fps, iso=$iso, latitude=$latitude, lensModel=$lensModel, longitude=$longitude, make=$make, model=$model, modifyDate=$modifyDate, orientation=$orientation, profileDescription=$profileDescription, projectionType=$projectionType, rating=$rating, state=$state, timeZone=$timeZone]';
|
String toString() => 'SyncAssetExifV1[assetId=$assetId, city=$city, country=$country, dateTimeOriginal=$dateTimeOriginal, description=$description, exifImageHeight=$exifImageHeight, exifImageWidth=$exifImageWidth, exposureTime=$exposureTime, fNumber=$fNumber, fileSizeInByte=$fileSizeInByte, focalLength=$focalLength, fps=$fps, iso=$iso, latitude=$latitude, lensModel=$lensModel, longitude=$longitude, make=$make, model=$model, modifyDate=$modifyDate, orientation=$orientation, profileDescription=$profileDescription, projectionType=$projectionType, rating=$rating, state=$state, timeZone=$timeZone]';
|
||||||
@ -153,171 +153,171 @@ class SyncAssetExifV1 {
|
|||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
json[r'assetId'] = this.assetId;
|
json[r'assetId'] = this.assetId;
|
||||||
if (this.city.unwrapOrNull() != null) {
|
if (this.city?.isSome ?? false) {
|
||||||
json[r'city'] = this.city;
|
json[r'city'] = this.city;
|
||||||
} else {
|
} else {
|
||||||
if(this.city.isSome) {
|
if(this.city?.isNone ?? false) {
|
||||||
json[r'city'] = null;
|
json[r'city'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.country.unwrapOrNull() != null) {
|
if (this.country?.isSome ?? false) {
|
||||||
json[r'country'] = this.country;
|
json[r'country'] = this.country;
|
||||||
} else {
|
} else {
|
||||||
if(this.country.isSome) {
|
if(this.country?.isNone ?? false) {
|
||||||
json[r'country'] = null;
|
json[r'country'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.dateTimeOriginal.unwrapOrNull() != null) {
|
if (this.dateTimeOriginal?.isSome ?? false) {
|
||||||
json[r'dateTimeOriginal'] = this.dateTimeOriginal.unwrap().toUtc().toIso8601String();
|
json[r'dateTimeOriginal'] = this.dateTimeOriginal!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.dateTimeOriginal.isSome) {
|
if(this.dateTimeOriginal?.isNone ?? false) {
|
||||||
json[r'dateTimeOriginal'] = null;
|
json[r'dateTimeOriginal'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.description.unwrapOrNull() != null) {
|
if (this.description?.isSome ?? false) {
|
||||||
json[r'description'] = this.description;
|
json[r'description'] = this.description;
|
||||||
} else {
|
} else {
|
||||||
if(this.description.isSome) {
|
if(this.description?.isNone ?? false) {
|
||||||
json[r'description'] = null;
|
json[r'description'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.exifImageHeight.unwrapOrNull() != null) {
|
if (this.exifImageHeight?.isSome ?? false) {
|
||||||
json[r'exifImageHeight'] = this.exifImageHeight;
|
json[r'exifImageHeight'] = this.exifImageHeight;
|
||||||
} else {
|
} else {
|
||||||
if(this.exifImageHeight.isSome) {
|
if(this.exifImageHeight?.isNone ?? false) {
|
||||||
json[r'exifImageHeight'] = null;
|
json[r'exifImageHeight'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.exifImageWidth.unwrapOrNull() != null) {
|
if (this.exifImageWidth?.isSome ?? false) {
|
||||||
json[r'exifImageWidth'] = this.exifImageWidth;
|
json[r'exifImageWidth'] = this.exifImageWidth;
|
||||||
} else {
|
} else {
|
||||||
if(this.exifImageWidth.isSome) {
|
if(this.exifImageWidth?.isNone ?? false) {
|
||||||
json[r'exifImageWidth'] = null;
|
json[r'exifImageWidth'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.exposureTime.unwrapOrNull() != null) {
|
if (this.exposureTime?.isSome ?? false) {
|
||||||
json[r'exposureTime'] = this.exposureTime;
|
json[r'exposureTime'] = this.exposureTime;
|
||||||
} else {
|
} else {
|
||||||
if(this.exposureTime.isSome) {
|
if(this.exposureTime?.isNone ?? false) {
|
||||||
json[r'exposureTime'] = null;
|
json[r'exposureTime'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.fNumber.unwrapOrNull() != null) {
|
if (this.fNumber?.isSome ?? false) {
|
||||||
json[r'fNumber'] = this.fNumber;
|
json[r'fNumber'] = this.fNumber;
|
||||||
} else {
|
} else {
|
||||||
if(this.fNumber.isSome) {
|
if(this.fNumber?.isNone ?? false) {
|
||||||
json[r'fNumber'] = null;
|
json[r'fNumber'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.fileSizeInByte.unwrapOrNull() != null) {
|
if (this.fileSizeInByte?.isSome ?? false) {
|
||||||
json[r'fileSizeInByte'] = this.fileSizeInByte;
|
json[r'fileSizeInByte'] = this.fileSizeInByte;
|
||||||
} else {
|
} else {
|
||||||
if(this.fileSizeInByte.isSome) {
|
if(this.fileSizeInByte?.isNone ?? false) {
|
||||||
json[r'fileSizeInByte'] = null;
|
json[r'fileSizeInByte'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.focalLength.unwrapOrNull() != null) {
|
if (this.focalLength?.isSome ?? false) {
|
||||||
json[r'focalLength'] = this.focalLength;
|
json[r'focalLength'] = this.focalLength;
|
||||||
} else {
|
} else {
|
||||||
if(this.focalLength.isSome) {
|
if(this.focalLength?.isNone ?? false) {
|
||||||
json[r'focalLength'] = null;
|
json[r'focalLength'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.fps.unwrapOrNull() != null) {
|
if (this.fps?.isSome ?? false) {
|
||||||
json[r'fps'] = this.fps;
|
json[r'fps'] = this.fps;
|
||||||
} else {
|
} else {
|
||||||
if(this.fps.isSome) {
|
if(this.fps?.isNone ?? false) {
|
||||||
json[r'fps'] = null;
|
json[r'fps'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.iso.unwrapOrNull() != null) {
|
if (this.iso?.isSome ?? false) {
|
||||||
json[r'iso'] = this.iso;
|
json[r'iso'] = this.iso;
|
||||||
} else {
|
} else {
|
||||||
if(this.iso.isSome) {
|
if(this.iso?.isNone ?? false) {
|
||||||
json[r'iso'] = null;
|
json[r'iso'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.latitude.unwrapOrNull() != null) {
|
if (this.latitude?.isSome ?? false) {
|
||||||
json[r'latitude'] = this.latitude;
|
json[r'latitude'] = this.latitude;
|
||||||
} else {
|
} else {
|
||||||
if(this.latitude.isSome) {
|
if(this.latitude?.isNone ?? false) {
|
||||||
json[r'latitude'] = null;
|
json[r'latitude'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.lensModel.unwrapOrNull() != null) {
|
if (this.lensModel?.isSome ?? false) {
|
||||||
json[r'lensModel'] = this.lensModel;
|
json[r'lensModel'] = this.lensModel;
|
||||||
} else {
|
} else {
|
||||||
if(this.lensModel.isSome) {
|
if(this.lensModel?.isNone ?? false) {
|
||||||
json[r'lensModel'] = null;
|
json[r'lensModel'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.longitude.unwrapOrNull() != null) {
|
if (this.longitude?.isSome ?? false) {
|
||||||
json[r'longitude'] = this.longitude;
|
json[r'longitude'] = this.longitude;
|
||||||
} else {
|
} else {
|
||||||
if(this.longitude.isSome) {
|
if(this.longitude?.isNone ?? false) {
|
||||||
json[r'longitude'] = null;
|
json[r'longitude'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.make.unwrapOrNull() != null) {
|
if (this.make?.isSome ?? false) {
|
||||||
json[r'make'] = this.make;
|
json[r'make'] = this.make;
|
||||||
} else {
|
} else {
|
||||||
if(this.make.isSome) {
|
if(this.make?.isNone ?? false) {
|
||||||
json[r'make'] = null;
|
json[r'make'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.model.unwrapOrNull() != null) {
|
if (this.model?.isSome ?? false) {
|
||||||
json[r'model'] = this.model;
|
json[r'model'] = this.model;
|
||||||
} else {
|
} else {
|
||||||
if(this.model.isSome) {
|
if(this.model?.isNone ?? false) {
|
||||||
json[r'model'] = null;
|
json[r'model'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.modifyDate.unwrapOrNull() != null) {
|
if (this.modifyDate?.isSome ?? false) {
|
||||||
json[r'modifyDate'] = this.modifyDate.unwrap().toUtc().toIso8601String();
|
json[r'modifyDate'] = this.modifyDate!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.modifyDate.isSome) {
|
if(this.modifyDate?.isNone ?? false) {
|
||||||
json[r'modifyDate'] = null;
|
json[r'modifyDate'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.orientation.unwrapOrNull() != null) {
|
if (this.orientation?.isSome ?? false) {
|
||||||
json[r'orientation'] = this.orientation;
|
json[r'orientation'] = this.orientation;
|
||||||
} else {
|
} else {
|
||||||
if(this.orientation.isSome) {
|
if(this.orientation?.isNone ?? false) {
|
||||||
json[r'orientation'] = null;
|
json[r'orientation'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.profileDescription.unwrapOrNull() != null) {
|
if (this.profileDescription?.isSome ?? false) {
|
||||||
json[r'profileDescription'] = this.profileDescription;
|
json[r'profileDescription'] = this.profileDescription;
|
||||||
} else {
|
} else {
|
||||||
if(this.profileDescription.isSome) {
|
if(this.profileDescription?.isNone ?? false) {
|
||||||
json[r'profileDescription'] = null;
|
json[r'profileDescription'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.projectionType.unwrapOrNull() != null) {
|
if (this.projectionType?.isSome ?? false) {
|
||||||
json[r'projectionType'] = this.projectionType;
|
json[r'projectionType'] = this.projectionType;
|
||||||
} else {
|
} else {
|
||||||
if(this.projectionType.isSome) {
|
if(this.projectionType?.isNone ?? false) {
|
||||||
json[r'projectionType'] = null;
|
json[r'projectionType'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.rating.unwrapOrNull() != null) {
|
if (this.rating?.isSome ?? false) {
|
||||||
json[r'rating'] = this.rating;
|
json[r'rating'] = this.rating;
|
||||||
} else {
|
} else {
|
||||||
if(this.rating.isSome) {
|
if(this.rating?.isNone ?? false) {
|
||||||
json[r'rating'] = null;
|
json[r'rating'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.state.unwrapOrNull() != null) {
|
if (this.state?.isSome ?? false) {
|
||||||
json[r'state'] = this.state;
|
json[r'state'] = this.state;
|
||||||
} else {
|
} else {
|
||||||
if(this.state.isSome) {
|
if(this.state?.isNone ?? false) {
|
||||||
json[r'state'] = null;
|
json[r'state'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.timeZone.unwrapOrNull() != null) {
|
if (this.timeZone?.isSome ?? false) {
|
||||||
json[r'timeZone'] = this.timeZone;
|
json[r'timeZone'] = this.timeZone;
|
||||||
} else {
|
} else {
|
||||||
if(this.timeZone.isSome) {
|
if(this.timeZone?.isNone ?? false) {
|
||||||
json[r'timeZone'] = null;
|
json[r'timeZone'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
58
mobile/openapi/lib/model/sync_asset_v1.dart
generated
58
mobile/openapi/lib/model/sync_asset_v1.dart
generated
@ -14,35 +14,35 @@ class SyncAssetV1 {
|
|||||||
/// Returns a new [SyncAssetV1] instance.
|
/// Returns a new [SyncAssetV1] instance.
|
||||||
SyncAssetV1({
|
SyncAssetV1({
|
||||||
required this.checksum,
|
required this.checksum,
|
||||||
this.deletedAt = const None(),
|
required this.deletedAt,
|
||||||
this.fileCreatedAt = const None(),
|
required this.fileCreatedAt,
|
||||||
this.fileModifiedAt = const None(),
|
required this.fileModifiedAt,
|
||||||
required this.id,
|
required this.id,
|
||||||
required this.isFavorite,
|
required this.isFavorite,
|
||||||
this.localDateTime = const None(),
|
required this.localDateTime,
|
||||||
required this.ownerId,
|
required this.ownerId,
|
||||||
this.thumbhash = const None(),
|
required this.thumbhash,
|
||||||
required this.type,
|
required this.type,
|
||||||
required this.visibility,
|
required this.visibility,
|
||||||
});
|
});
|
||||||
|
|
||||||
String checksum;
|
String checksum;
|
||||||
|
|
||||||
Option<DateTime> deletedAt;
|
Option<DateTime>? deletedAt;
|
||||||
|
|
||||||
Option<DateTime> fileCreatedAt;
|
Option<DateTime>? fileCreatedAt;
|
||||||
|
|
||||||
Option<DateTime> fileModifiedAt;
|
Option<DateTime>? fileModifiedAt;
|
||||||
|
|
||||||
String id;
|
String id;
|
||||||
|
|
||||||
bool isFavorite;
|
bool isFavorite;
|
||||||
|
|
||||||
Option<DateTime> localDateTime;
|
Option<DateTime>? localDateTime;
|
||||||
|
|
||||||
String ownerId;
|
String ownerId;
|
||||||
|
|
||||||
Option<String> thumbhash;
|
Option<String>? thumbhash;
|
||||||
|
|
||||||
SyncAssetV1TypeEnum type;
|
SyncAssetV1TypeEnum type;
|
||||||
|
|
||||||
@ -66,14 +66,14 @@ class SyncAssetV1 {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(checksum.hashCode) +
|
(checksum.hashCode) +
|
||||||
(deletedAt.hashCode) +
|
(deletedAt == null ? 0 : deletedAt!.hashCode) +
|
||||||
(fileCreatedAt.hashCode) +
|
(fileCreatedAt == null ? 0 : fileCreatedAt!.hashCode) +
|
||||||
(fileModifiedAt.hashCode) +
|
(fileModifiedAt == null ? 0 : fileModifiedAt!.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(isFavorite.hashCode) +
|
(isFavorite.hashCode) +
|
||||||
(localDateTime.hashCode) +
|
(localDateTime == null ? 0 : localDateTime!.hashCode) +
|
||||||
(ownerId.hashCode) +
|
(ownerId.hashCode) +
|
||||||
(thumbhash.hashCode) +
|
(thumbhash == null ? 0 : thumbhash!.hashCode) +
|
||||||
(type.hashCode) +
|
(type.hashCode) +
|
||||||
(visibility.hashCode);
|
(visibility.hashCode);
|
||||||
|
|
||||||
@ -83,41 +83,41 @@ class SyncAssetV1 {
|
|||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
json[r'checksum'] = this.checksum;
|
json[r'checksum'] = this.checksum;
|
||||||
if (this.deletedAt.unwrapOrNull() != null) {
|
if (this.deletedAt?.isSome ?? false) {
|
||||||
json[r'deletedAt'] = this.deletedAt.unwrap().toUtc().toIso8601String();
|
json[r'deletedAt'] = this.deletedAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.deletedAt.isSome) {
|
if(this.deletedAt?.isNone ?? false) {
|
||||||
json[r'deletedAt'] = null;
|
json[r'deletedAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.fileCreatedAt.unwrapOrNull() != null) {
|
if (this.fileCreatedAt?.isSome ?? false) {
|
||||||
json[r'fileCreatedAt'] = this.fileCreatedAt.unwrap().toUtc().toIso8601String();
|
json[r'fileCreatedAt'] = this.fileCreatedAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.fileCreatedAt.isSome) {
|
if(this.fileCreatedAt?.isNone ?? false) {
|
||||||
json[r'fileCreatedAt'] = null;
|
json[r'fileCreatedAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.fileModifiedAt.unwrapOrNull() != null) {
|
if (this.fileModifiedAt?.isSome ?? false) {
|
||||||
json[r'fileModifiedAt'] = this.fileModifiedAt.unwrap().toUtc().toIso8601String();
|
json[r'fileModifiedAt'] = this.fileModifiedAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.fileModifiedAt.isSome) {
|
if(this.fileModifiedAt?.isNone ?? false) {
|
||||||
json[r'fileModifiedAt'] = null;
|
json[r'fileModifiedAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
json[r'id'] = this.id;
|
json[r'id'] = this.id;
|
||||||
json[r'isFavorite'] = this.isFavorite;
|
json[r'isFavorite'] = this.isFavorite;
|
||||||
if (this.localDateTime.unwrapOrNull() != null) {
|
if (this.localDateTime?.isSome ?? false) {
|
||||||
json[r'localDateTime'] = this.localDateTime.unwrap().toUtc().toIso8601String();
|
json[r'localDateTime'] = this.localDateTime!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.localDateTime.isSome) {
|
if(this.localDateTime?.isNone ?? false) {
|
||||||
json[r'localDateTime'] = null;
|
json[r'localDateTime'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
json[r'ownerId'] = this.ownerId;
|
json[r'ownerId'] = this.ownerId;
|
||||||
if (this.thumbhash.unwrapOrNull() != null) {
|
if (this.thumbhash?.isSome ?? false) {
|
||||||
json[r'thumbhash'] = this.thumbhash;
|
json[r'thumbhash'] = this.thumbhash;
|
||||||
} else {
|
} else {
|
||||||
if(this.thumbhash.isSome) {
|
if(this.thumbhash?.isNone ?? false) {
|
||||||
json[r'thumbhash'] = null;
|
json[r'thumbhash'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
12
mobile/openapi/lib/model/sync_user_v1.dart
generated
12
mobile/openapi/lib/model/sync_user_v1.dart
generated
@ -13,13 +13,13 @@ part of openapi.api;
|
|||||||
class SyncUserV1 {
|
class SyncUserV1 {
|
||||||
/// Returns a new [SyncUserV1] instance.
|
/// Returns a new [SyncUserV1] instance.
|
||||||
SyncUserV1({
|
SyncUserV1({
|
||||||
this.deletedAt = const None(),
|
required this.deletedAt,
|
||||||
required this.email,
|
required this.email,
|
||||||
required this.id,
|
required this.id,
|
||||||
required this.name,
|
required this.name,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<DateTime> deletedAt;
|
Option<DateTime>? deletedAt;
|
||||||
|
|
||||||
String email;
|
String email;
|
||||||
|
|
||||||
@ -37,7 +37,7 @@ class SyncUserV1 {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(deletedAt.hashCode) +
|
(deletedAt == null ? 0 : deletedAt!.hashCode) +
|
||||||
(email.hashCode) +
|
(email.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(name.hashCode);
|
(name.hashCode);
|
||||||
@ -47,10 +47,10 @@ class SyncUserV1 {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.deletedAt.unwrapOrNull() != null) {
|
if (this.deletedAt?.isSome ?? false) {
|
||||||
json[r'deletedAt'] = this.deletedAt.unwrap().toUtc().toIso8601String();
|
json[r'deletedAt'] = this.deletedAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.deletedAt.isSome) {
|
if(this.deletedAt?.isNone ?? false) {
|
||||||
json[r'deletedAt'] = null;
|
json[r'deletedAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
10
mobile/openapi/lib/model/tag_create_dto.dart
generated
10
mobile/openapi/lib/model/tag_create_dto.dart
generated
@ -15,7 +15,7 @@ class TagCreateDto {
|
|||||||
TagCreateDto({
|
TagCreateDto({
|
||||||
this.color,
|
this.color,
|
||||||
required this.name,
|
required this.name,
|
||||||
this.parentId = const None(),
|
this.parentId,
|
||||||
});
|
});
|
||||||
|
|
||||||
///
|
///
|
||||||
@ -28,7 +28,7 @@ class TagCreateDto {
|
|||||||
|
|
||||||
String name;
|
String name;
|
||||||
|
|
||||||
Option<String> parentId;
|
Option<String>? parentId;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is TagCreateDto &&
|
bool operator ==(Object other) => identical(this, other) || other is TagCreateDto &&
|
||||||
@ -41,7 +41,7 @@ class TagCreateDto {
|
|||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(color == null ? 0 : color!.hashCode) +
|
(color == null ? 0 : color!.hashCode) +
|
||||||
(name.hashCode) +
|
(name.hashCode) +
|
||||||
(parentId.hashCode);
|
(parentId == null ? 0 : parentId!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'TagCreateDto[color=$color, name=$name, parentId=$parentId]';
|
String toString() => 'TagCreateDto[color=$color, name=$name, parentId=$parentId]';
|
||||||
@ -54,10 +54,10 @@ class TagCreateDto {
|
|||||||
// json[r'color'] = null;
|
// json[r'color'] = null;
|
||||||
}
|
}
|
||||||
json[r'name'] = this.name;
|
json[r'name'] = this.name;
|
||||||
if (this.parentId.unwrapOrNull() != null) {
|
if (this.parentId?.isSome ?? false) {
|
||||||
json[r'parentId'] = this.parentId;
|
json[r'parentId'] = this.parentId;
|
||||||
} else {
|
} else {
|
||||||
if(this.parentId.isSome) {
|
if(this.parentId?.isNone ?? false) {
|
||||||
json[r'parentId'] = null;
|
json[r'parentId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
10
mobile/openapi/lib/model/tag_update_dto.dart
generated
10
mobile/openapi/lib/model/tag_update_dto.dart
generated
@ -13,10 +13,10 @@ part of openapi.api;
|
|||||||
class TagUpdateDto {
|
class TagUpdateDto {
|
||||||
/// Returns a new [TagUpdateDto] instance.
|
/// Returns a new [TagUpdateDto] instance.
|
||||||
TagUpdateDto({
|
TagUpdateDto({
|
||||||
this.color = const None(),
|
this.color,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<String> color;
|
Option<String>? color;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is TagUpdateDto &&
|
bool operator ==(Object other) => identical(this, other) || other is TagUpdateDto &&
|
||||||
@ -25,17 +25,17 @@ class TagUpdateDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(color.hashCode);
|
(color == null ? 0 : color!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'TagUpdateDto[color=$color]';
|
String toString() => 'TagUpdateDto[color=$color]';
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.color.unwrapOrNull() != null) {
|
if (this.color?.isSome ?? false) {
|
||||||
json[r'color'] = this.color;
|
json[r'color'] = this.color;
|
||||||
} else {
|
} else {
|
||||||
if(this.color.isSome) {
|
if(this.color?.isNone ?? false) {
|
||||||
json[r'color'] = null;
|
json[r'color'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
10
mobile/openapi/lib/model/update_asset_dto.dart
generated
10
mobile/openapi/lib/model/update_asset_dto.dart
generated
@ -17,7 +17,7 @@ class UpdateAssetDto {
|
|||||||
this.description,
|
this.description,
|
||||||
this.isFavorite,
|
this.isFavorite,
|
||||||
this.latitude,
|
this.latitude,
|
||||||
this.livePhotoVideoId = const None(),
|
this.livePhotoVideoId,
|
||||||
this.longitude,
|
this.longitude,
|
||||||
this.rating,
|
this.rating,
|
||||||
this.visibility,
|
this.visibility,
|
||||||
@ -55,7 +55,7 @@ class UpdateAssetDto {
|
|||||||
///
|
///
|
||||||
num? latitude;
|
num? latitude;
|
||||||
|
|
||||||
Option<String> livePhotoVideoId;
|
Option<String>? livePhotoVideoId;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -101,7 +101,7 @@ class UpdateAssetDto {
|
|||||||
(description == null ? 0 : description!.hashCode) +
|
(description == null ? 0 : description!.hashCode) +
|
||||||
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
(isFavorite == null ? 0 : isFavorite!.hashCode) +
|
||||||
(latitude == null ? 0 : latitude!.hashCode) +
|
(latitude == null ? 0 : latitude!.hashCode) +
|
||||||
(livePhotoVideoId.hashCode) +
|
(livePhotoVideoId == null ? 0 : livePhotoVideoId!.hashCode) +
|
||||||
(longitude == null ? 0 : longitude!.hashCode) +
|
(longitude == null ? 0 : longitude!.hashCode) +
|
||||||
(rating == null ? 0 : rating!.hashCode) +
|
(rating == null ? 0 : rating!.hashCode) +
|
||||||
(visibility == null ? 0 : visibility!.hashCode);
|
(visibility == null ? 0 : visibility!.hashCode);
|
||||||
@ -131,10 +131,10 @@ class UpdateAssetDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'latitude'] = null;
|
// json[r'latitude'] = null;
|
||||||
}
|
}
|
||||||
if (this.livePhotoVideoId.unwrapOrNull() != null) {
|
if (this.livePhotoVideoId?.isSome ?? false) {
|
||||||
json[r'livePhotoVideoId'] = this.livePhotoVideoId;
|
json[r'livePhotoVideoId'] = this.livePhotoVideoId;
|
||||||
} else {
|
} else {
|
||||||
if(this.livePhotoVideoId.isSome) {
|
if(this.livePhotoVideoId?.isNone ?? false) {
|
||||||
json[r'livePhotoVideoId'] = null;
|
json[r'livePhotoVideoId'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
10
mobile/openapi/lib/model/usage_by_user_dto.dart
generated
10
mobile/openapi/lib/model/usage_by_user_dto.dart
generated
@ -14,7 +14,7 @@ class UsageByUserDto {
|
|||||||
/// Returns a new [UsageByUserDto] instance.
|
/// Returns a new [UsageByUserDto] instance.
|
||||||
UsageByUserDto({
|
UsageByUserDto({
|
||||||
required this.photos,
|
required this.photos,
|
||||||
this.quotaSizeInBytes = const None(),
|
required this.quotaSizeInBytes,
|
||||||
required this.usage,
|
required this.usage,
|
||||||
required this.usagePhotos,
|
required this.usagePhotos,
|
||||||
required this.usageVideos,
|
required this.usageVideos,
|
||||||
@ -25,7 +25,7 @@ class UsageByUserDto {
|
|||||||
|
|
||||||
int photos;
|
int photos;
|
||||||
|
|
||||||
Option<int> quotaSizeInBytes;
|
Option<int>? quotaSizeInBytes;
|
||||||
|
|
||||||
int usage;
|
int usage;
|
||||||
|
|
||||||
@ -54,7 +54,7 @@ class UsageByUserDto {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(photos.hashCode) +
|
(photos.hashCode) +
|
||||||
(quotaSizeInBytes.hashCode) +
|
(quotaSizeInBytes == null ? 0 : quotaSizeInBytes!.hashCode) +
|
||||||
(usage.hashCode) +
|
(usage.hashCode) +
|
||||||
(usagePhotos.hashCode) +
|
(usagePhotos.hashCode) +
|
||||||
(usageVideos.hashCode) +
|
(usageVideos.hashCode) +
|
||||||
@ -68,10 +68,10 @@ class UsageByUserDto {
|
|||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
json[r'photos'] = this.photos;
|
json[r'photos'] = this.photos;
|
||||||
if (this.quotaSizeInBytes.unwrapOrNull() != null) {
|
if (this.quotaSizeInBytes?.isSome ?? false) {
|
||||||
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
||||||
} else {
|
} else {
|
||||||
if(this.quotaSizeInBytes.isSome) {
|
if(this.quotaSizeInBytes?.isNone ?? false) {
|
||||||
json[r'quotaSizeInBytes'] = null;
|
json[r'quotaSizeInBytes'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
30
mobile/openapi/lib/model/user_admin_create_dto.dart
generated
30
mobile/openapi/lib/model/user_admin_create_dto.dart
generated
@ -13,17 +13,17 @@ part of openapi.api;
|
|||||||
class UserAdminCreateDto {
|
class UserAdminCreateDto {
|
||||||
/// Returns a new [UserAdminCreateDto] instance.
|
/// Returns a new [UserAdminCreateDto] instance.
|
||||||
UserAdminCreateDto({
|
UserAdminCreateDto({
|
||||||
this.avatarColor = const None(),
|
this.avatarColor,
|
||||||
required this.email,
|
required this.email,
|
||||||
required this.name,
|
required this.name,
|
||||||
this.notify,
|
this.notify,
|
||||||
required this.password,
|
required this.password,
|
||||||
this.quotaSizeInBytes = const None(),
|
this.quotaSizeInBytes,
|
||||||
this.shouldChangePassword,
|
this.shouldChangePassword,
|
||||||
this.storageLabel = const None(),
|
this.storageLabel,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<UserAvatarColor> avatarColor;
|
Option<UserAvatarColor>? avatarColor;
|
||||||
|
|
||||||
String email;
|
String email;
|
||||||
|
|
||||||
@ -40,7 +40,7 @@ class UserAdminCreateDto {
|
|||||||
String password;
|
String password;
|
||||||
|
|
||||||
/// Minimum value: 0
|
/// Minimum value: 0
|
||||||
Option<int> quotaSizeInBytes;
|
Option<int>? quotaSizeInBytes;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -50,7 +50,7 @@ class UserAdminCreateDto {
|
|||||||
///
|
///
|
||||||
bool? shouldChangePassword;
|
bool? shouldChangePassword;
|
||||||
|
|
||||||
Option<String> storageLabel;
|
Option<String>? storageLabel;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is UserAdminCreateDto &&
|
bool operator ==(Object other) => identical(this, other) || other is UserAdminCreateDto &&
|
||||||
@ -66,24 +66,24 @@ class UserAdminCreateDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(avatarColor.hashCode) +
|
(avatarColor == null ? 0 : avatarColor!.hashCode) +
|
||||||
(email.hashCode) +
|
(email.hashCode) +
|
||||||
(name.hashCode) +
|
(name.hashCode) +
|
||||||
(notify == null ? 0 : notify!.hashCode) +
|
(notify == null ? 0 : notify!.hashCode) +
|
||||||
(password.hashCode) +
|
(password.hashCode) +
|
||||||
(quotaSizeInBytes.hashCode) +
|
(quotaSizeInBytes == null ? 0 : quotaSizeInBytes!.hashCode) +
|
||||||
(shouldChangePassword == null ? 0 : shouldChangePassword!.hashCode) +
|
(shouldChangePassword == null ? 0 : shouldChangePassword!.hashCode) +
|
||||||
(storageLabel.hashCode);
|
(storageLabel == null ? 0 : storageLabel!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'UserAdminCreateDto[avatarColor=$avatarColor, email=$email, name=$name, notify=$notify, password=$password, quotaSizeInBytes=$quotaSizeInBytes, shouldChangePassword=$shouldChangePassword, storageLabel=$storageLabel]';
|
String toString() => 'UserAdminCreateDto[avatarColor=$avatarColor, email=$email, name=$name, notify=$notify, password=$password, quotaSizeInBytes=$quotaSizeInBytes, shouldChangePassword=$shouldChangePassword, storageLabel=$storageLabel]';
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.avatarColor.unwrapOrNull() != null) {
|
if (this.avatarColor?.isSome ?? false) {
|
||||||
json[r'avatarColor'] = this.avatarColor;
|
json[r'avatarColor'] = this.avatarColor;
|
||||||
} else {
|
} else {
|
||||||
if(this.avatarColor.isSome) {
|
if(this.avatarColor?.isNone ?? false) {
|
||||||
json[r'avatarColor'] = null;
|
json[r'avatarColor'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -95,10 +95,10 @@ class UserAdminCreateDto {
|
|||||||
// json[r'notify'] = null;
|
// json[r'notify'] = null;
|
||||||
}
|
}
|
||||||
json[r'password'] = this.password;
|
json[r'password'] = this.password;
|
||||||
if (this.quotaSizeInBytes.unwrapOrNull() != null) {
|
if (this.quotaSizeInBytes?.isSome ?? false) {
|
||||||
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
||||||
} else {
|
} else {
|
||||||
if(this.quotaSizeInBytes.isSome) {
|
if(this.quotaSizeInBytes?.isNone ?? false) {
|
||||||
json[r'quotaSizeInBytes'] = null;
|
json[r'quotaSizeInBytes'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -107,10 +107,10 @@ class UserAdminCreateDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'shouldChangePassword'] = null;
|
// json[r'shouldChangePassword'] = null;
|
||||||
}
|
}
|
||||||
if (this.storageLabel.unwrapOrNull() != null) {
|
if (this.storageLabel?.isSome ?? false) {
|
||||||
json[r'storageLabel'] = this.storageLabel;
|
json[r'storageLabel'] = this.storageLabel;
|
||||||
} else {
|
} else {
|
||||||
if(this.storageLabel.isSome) {
|
if(this.storageLabel?.isNone ?? false) {
|
||||||
json[r'storageLabel'] = null;
|
json[r'storageLabel'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -15,20 +15,20 @@ class UserAdminResponseDto {
|
|||||||
UserAdminResponseDto({
|
UserAdminResponseDto({
|
||||||
required this.avatarColor,
|
required this.avatarColor,
|
||||||
required this.createdAt,
|
required this.createdAt,
|
||||||
this.deletedAt = const None(),
|
required this.deletedAt,
|
||||||
required this.email,
|
required this.email,
|
||||||
required this.id,
|
required this.id,
|
||||||
required this.isAdmin,
|
required this.isAdmin,
|
||||||
this.license = const None(),
|
required this.license,
|
||||||
required this.name,
|
required this.name,
|
||||||
required this.oauthId,
|
required this.oauthId,
|
||||||
required this.profileChangedAt,
|
required this.profileChangedAt,
|
||||||
required this.profileImagePath,
|
required this.profileImagePath,
|
||||||
this.quotaSizeInBytes = const None(),
|
required this.quotaSizeInBytes,
|
||||||
this.quotaUsageInBytes = const None(),
|
required this.quotaUsageInBytes,
|
||||||
required this.shouldChangePassword,
|
required this.shouldChangePassword,
|
||||||
required this.status,
|
required this.status,
|
||||||
this.storageLabel = const None(),
|
required this.storageLabel,
|
||||||
required this.updatedAt,
|
required this.updatedAt,
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -36,7 +36,7 @@ class UserAdminResponseDto {
|
|||||||
|
|
||||||
DateTime createdAt;
|
DateTime createdAt;
|
||||||
|
|
||||||
Option<DateTime> deletedAt;
|
Option<DateTime>? deletedAt;
|
||||||
|
|
||||||
String email;
|
String email;
|
||||||
|
|
||||||
@ -44,7 +44,7 @@ class UserAdminResponseDto {
|
|||||||
|
|
||||||
bool isAdmin;
|
bool isAdmin;
|
||||||
|
|
||||||
Option<UserLicense> license;
|
Option<UserLicense>? license;
|
||||||
|
|
||||||
String name;
|
String name;
|
||||||
|
|
||||||
@ -54,15 +54,15 @@ class UserAdminResponseDto {
|
|||||||
|
|
||||||
String profileImagePath;
|
String profileImagePath;
|
||||||
|
|
||||||
Option<int> quotaSizeInBytes;
|
Option<int>? quotaSizeInBytes;
|
||||||
|
|
||||||
Option<int> quotaUsageInBytes;
|
Option<int>? quotaUsageInBytes;
|
||||||
|
|
||||||
bool shouldChangePassword;
|
bool shouldChangePassword;
|
||||||
|
|
||||||
UserStatus status;
|
UserStatus status;
|
||||||
|
|
||||||
Option<String> storageLabel;
|
Option<String>? storageLabel;
|
||||||
|
|
||||||
DateTime updatedAt;
|
DateTime updatedAt;
|
||||||
|
|
||||||
@ -91,20 +91,20 @@ class UserAdminResponseDto {
|
|||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(avatarColor.hashCode) +
|
(avatarColor.hashCode) +
|
||||||
(createdAt.hashCode) +
|
(createdAt.hashCode) +
|
||||||
(deletedAt.hashCode) +
|
(deletedAt == null ? 0 : deletedAt!.hashCode) +
|
||||||
(email.hashCode) +
|
(email.hashCode) +
|
||||||
(id.hashCode) +
|
(id.hashCode) +
|
||||||
(isAdmin.hashCode) +
|
(isAdmin.hashCode) +
|
||||||
(license.hashCode) +
|
(license == null ? 0 : license!.hashCode) +
|
||||||
(name.hashCode) +
|
(name.hashCode) +
|
||||||
(oauthId.hashCode) +
|
(oauthId.hashCode) +
|
||||||
(profileChangedAt.hashCode) +
|
(profileChangedAt.hashCode) +
|
||||||
(profileImagePath.hashCode) +
|
(profileImagePath.hashCode) +
|
||||||
(quotaSizeInBytes.hashCode) +
|
(quotaSizeInBytes == null ? 0 : quotaSizeInBytes!.hashCode) +
|
||||||
(quotaUsageInBytes.hashCode) +
|
(quotaUsageInBytes == null ? 0 : quotaUsageInBytes!.hashCode) +
|
||||||
(shouldChangePassword.hashCode) +
|
(shouldChangePassword.hashCode) +
|
||||||
(status.hashCode) +
|
(status.hashCode) +
|
||||||
(storageLabel.hashCode) +
|
(storageLabel == null ? 0 : storageLabel!.hashCode) +
|
||||||
(updatedAt.hashCode);
|
(updatedAt.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@ -114,20 +114,20 @@ class UserAdminResponseDto {
|
|||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
json[r'avatarColor'] = this.avatarColor;
|
json[r'avatarColor'] = this.avatarColor;
|
||||||
json[r'createdAt'] = this.createdAt.toUtc().toIso8601String();
|
json[r'createdAt'] = this.createdAt.toUtc().toIso8601String();
|
||||||
if (this.deletedAt.unwrapOrNull() != null) {
|
if (this.deletedAt?.isSome ?? false) {
|
||||||
json[r'deletedAt'] = this.deletedAt.unwrap().toUtc().toIso8601String();
|
json[r'deletedAt'] = this.deletedAt!.unwrap().toUtc().toIso8601String();
|
||||||
} else {
|
} else {
|
||||||
if(this.deletedAt.isSome) {
|
if(this.deletedAt?.isNone ?? false) {
|
||||||
json[r'deletedAt'] = null;
|
json[r'deletedAt'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
json[r'email'] = this.email;
|
json[r'email'] = this.email;
|
||||||
json[r'id'] = this.id;
|
json[r'id'] = this.id;
|
||||||
json[r'isAdmin'] = this.isAdmin;
|
json[r'isAdmin'] = this.isAdmin;
|
||||||
if (this.license.unwrapOrNull() != null) {
|
if (this.license?.isSome ?? false) {
|
||||||
json[r'license'] = this.license;
|
json[r'license'] = this.license;
|
||||||
} else {
|
} else {
|
||||||
if(this.license.isSome) {
|
if(this.license?.isNone ?? false) {
|
||||||
json[r'license'] = null;
|
json[r'license'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -135,26 +135,26 @@ class UserAdminResponseDto {
|
|||||||
json[r'oauthId'] = this.oauthId;
|
json[r'oauthId'] = this.oauthId;
|
||||||
json[r'profileChangedAt'] = this.profileChangedAt.toUtc().toIso8601String();
|
json[r'profileChangedAt'] = this.profileChangedAt.toUtc().toIso8601String();
|
||||||
json[r'profileImagePath'] = this.profileImagePath;
|
json[r'profileImagePath'] = this.profileImagePath;
|
||||||
if (this.quotaSizeInBytes.unwrapOrNull() != null) {
|
if (this.quotaSizeInBytes?.isSome ?? false) {
|
||||||
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
||||||
} else {
|
} else {
|
||||||
if(this.quotaSizeInBytes.isSome) {
|
if(this.quotaSizeInBytes?.isNone ?? false) {
|
||||||
json[r'quotaSizeInBytes'] = null;
|
json[r'quotaSizeInBytes'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.quotaUsageInBytes.unwrapOrNull() != null) {
|
if (this.quotaUsageInBytes?.isSome ?? false) {
|
||||||
json[r'quotaUsageInBytes'] = this.quotaUsageInBytes;
|
json[r'quotaUsageInBytes'] = this.quotaUsageInBytes;
|
||||||
} else {
|
} else {
|
||||||
if(this.quotaUsageInBytes.isSome) {
|
if(this.quotaUsageInBytes?.isNone ?? false) {
|
||||||
json[r'quotaUsageInBytes'] = null;
|
json[r'quotaUsageInBytes'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
json[r'shouldChangePassword'] = this.shouldChangePassword;
|
json[r'shouldChangePassword'] = this.shouldChangePassword;
|
||||||
json[r'status'] = this.status;
|
json[r'status'] = this.status;
|
||||||
if (this.storageLabel.unwrapOrNull() != null) {
|
if (this.storageLabel?.isSome ?? false) {
|
||||||
json[r'storageLabel'] = this.storageLabel;
|
json[r'storageLabel'] = this.storageLabel;
|
||||||
} else {
|
} else {
|
||||||
if(this.storageLabel.isSome) {
|
if(this.storageLabel?.isNone ?? false) {
|
||||||
json[r'storageLabel'] = null;
|
json[r'storageLabel'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
40
mobile/openapi/lib/model/user_admin_update_dto.dart
generated
40
mobile/openapi/lib/model/user_admin_update_dto.dart
generated
@ -13,17 +13,17 @@ part of openapi.api;
|
|||||||
class UserAdminUpdateDto {
|
class UserAdminUpdateDto {
|
||||||
/// Returns a new [UserAdminUpdateDto] instance.
|
/// Returns a new [UserAdminUpdateDto] instance.
|
||||||
UserAdminUpdateDto({
|
UserAdminUpdateDto({
|
||||||
this.avatarColor = const None(),
|
this.avatarColor,
|
||||||
this.email,
|
this.email,
|
||||||
this.name,
|
this.name,
|
||||||
this.password,
|
this.password,
|
||||||
this.pinCode = const None(),
|
this.pinCode,
|
||||||
this.quotaSizeInBytes = const None(),
|
this.quotaSizeInBytes,
|
||||||
this.shouldChangePassword,
|
this.shouldChangePassword,
|
||||||
this.storageLabel = const None(),
|
this.storageLabel,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<UserAvatarColor> avatarColor;
|
Option<UserAvatarColor>? avatarColor;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -49,10 +49,10 @@ class UserAdminUpdateDto {
|
|||||||
///
|
///
|
||||||
String? password;
|
String? password;
|
||||||
|
|
||||||
Option<String> pinCode;
|
Option<String>? pinCode;
|
||||||
|
|
||||||
/// Minimum value: 0
|
/// Minimum value: 0
|
||||||
Option<int> quotaSizeInBytes;
|
Option<int>? quotaSizeInBytes;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -62,7 +62,7 @@ class UserAdminUpdateDto {
|
|||||||
///
|
///
|
||||||
bool? shouldChangePassword;
|
bool? shouldChangePassword;
|
||||||
|
|
||||||
Option<String> storageLabel;
|
Option<String>? storageLabel;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool operator ==(Object other) => identical(this, other) || other is UserAdminUpdateDto &&
|
bool operator ==(Object other) => identical(this, other) || other is UserAdminUpdateDto &&
|
||||||
@ -78,24 +78,24 @@ class UserAdminUpdateDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(avatarColor.hashCode) +
|
(avatarColor == null ? 0 : avatarColor!.hashCode) +
|
||||||
(email == null ? 0 : email!.hashCode) +
|
(email == null ? 0 : email!.hashCode) +
|
||||||
(name == null ? 0 : name!.hashCode) +
|
(name == null ? 0 : name!.hashCode) +
|
||||||
(password == null ? 0 : password!.hashCode) +
|
(password == null ? 0 : password!.hashCode) +
|
||||||
(pinCode.hashCode) +
|
(pinCode == null ? 0 : pinCode!.hashCode) +
|
||||||
(quotaSizeInBytes.hashCode) +
|
(quotaSizeInBytes == null ? 0 : quotaSizeInBytes!.hashCode) +
|
||||||
(shouldChangePassword == null ? 0 : shouldChangePassword!.hashCode) +
|
(shouldChangePassword == null ? 0 : shouldChangePassword!.hashCode) +
|
||||||
(storageLabel.hashCode);
|
(storageLabel == null ? 0 : storageLabel!.hashCode);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
String toString() => 'UserAdminUpdateDto[avatarColor=$avatarColor, email=$email, name=$name, password=$password, pinCode=$pinCode, quotaSizeInBytes=$quotaSizeInBytes, shouldChangePassword=$shouldChangePassword, storageLabel=$storageLabel]';
|
String toString() => 'UserAdminUpdateDto[avatarColor=$avatarColor, email=$email, name=$name, password=$password, pinCode=$pinCode, quotaSizeInBytes=$quotaSizeInBytes, shouldChangePassword=$shouldChangePassword, storageLabel=$storageLabel]';
|
||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.avatarColor.unwrapOrNull() != null) {
|
if (this.avatarColor?.isSome ?? false) {
|
||||||
json[r'avatarColor'] = this.avatarColor;
|
json[r'avatarColor'] = this.avatarColor;
|
||||||
} else {
|
} else {
|
||||||
if(this.avatarColor.isSome) {
|
if(this.avatarColor?.isNone ?? false) {
|
||||||
json[r'avatarColor'] = null;
|
json[r'avatarColor'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -114,17 +114,17 @@ class UserAdminUpdateDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'password'] = null;
|
// json[r'password'] = null;
|
||||||
}
|
}
|
||||||
if (this.pinCode.unwrapOrNull() != null) {
|
if (this.pinCode?.isSome ?? false) {
|
||||||
json[r'pinCode'] = this.pinCode;
|
json[r'pinCode'] = this.pinCode;
|
||||||
} else {
|
} else {
|
||||||
if(this.pinCode.isSome) {
|
if(this.pinCode?.isNone ?? false) {
|
||||||
json[r'pinCode'] = null;
|
json[r'pinCode'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.quotaSizeInBytes.unwrapOrNull() != null) {
|
if (this.quotaSizeInBytes?.isSome ?? false) {
|
||||||
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
json[r'quotaSizeInBytes'] = this.quotaSizeInBytes;
|
||||||
} else {
|
} else {
|
||||||
if(this.quotaSizeInBytes.isSome) {
|
if(this.quotaSizeInBytes?.isNone ?? false) {
|
||||||
json[r'quotaSizeInBytes'] = null;
|
json[r'quotaSizeInBytes'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -133,10 +133,10 @@ class UserAdminUpdateDto {
|
|||||||
} else {
|
} else {
|
||||||
// json[r'shouldChangePassword'] = null;
|
// json[r'shouldChangePassword'] = null;
|
||||||
}
|
}
|
||||||
if (this.storageLabel.unwrapOrNull() != null) {
|
if (this.storageLabel?.isSome ?? false) {
|
||||||
json[r'storageLabel'] = this.storageLabel;
|
json[r'storageLabel'] = this.storageLabel;
|
||||||
} else {
|
} else {
|
||||||
if(this.storageLabel.isSome) {
|
if(this.storageLabel?.isNone ?? false) {
|
||||||
json[r'storageLabel'] = null;
|
json[r'storageLabel'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
10
mobile/openapi/lib/model/user_update_me_dto.dart
generated
10
mobile/openapi/lib/model/user_update_me_dto.dart
generated
@ -13,13 +13,13 @@ part of openapi.api;
|
|||||||
class UserUpdateMeDto {
|
class UserUpdateMeDto {
|
||||||
/// Returns a new [UserUpdateMeDto] instance.
|
/// Returns a new [UserUpdateMeDto] instance.
|
||||||
UserUpdateMeDto({
|
UserUpdateMeDto({
|
||||||
this.avatarColor = const None(),
|
this.avatarColor,
|
||||||
this.email,
|
this.email,
|
||||||
this.name,
|
this.name,
|
||||||
this.password,
|
this.password,
|
||||||
});
|
});
|
||||||
|
|
||||||
Option<UserAvatarColor> avatarColor;
|
Option<UserAvatarColor>? avatarColor;
|
||||||
|
|
||||||
///
|
///
|
||||||
/// Please note: This property should have been non-nullable! Since the specification file
|
/// Please note: This property should have been non-nullable! Since the specification file
|
||||||
@ -55,7 +55,7 @@ class UserUpdateMeDto {
|
|||||||
@override
|
@override
|
||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
(avatarColor.hashCode) +
|
(avatarColor == null ? 0 : avatarColor!.hashCode) +
|
||||||
(email == null ? 0 : email!.hashCode) +
|
(email == null ? 0 : email!.hashCode) +
|
||||||
(name == null ? 0 : name!.hashCode) +
|
(name == null ? 0 : name!.hashCode) +
|
||||||
(password == null ? 0 : password!.hashCode);
|
(password == null ? 0 : password!.hashCode);
|
||||||
@ -65,10 +65,10 @@ class UserUpdateMeDto {
|
|||||||
|
|
||||||
Map<String, dynamic> toJson() {
|
Map<String, dynamic> toJson() {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
if (this.avatarColor.unwrapOrNull() != null) {
|
if (this.avatarColor?.isSome ?? false) {
|
||||||
json[r'avatarColor'] = this.avatarColor;
|
json[r'avatarColor'] = this.avatarColor;
|
||||||
} else {
|
} else {
|
||||||
if(this.avatarColor.isSome) {
|
if(this.avatarColor?.isNone ?? false) {
|
||||||
json[r'avatarColor'] = null;
|
json[r'avatarColor'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,9 +13,6 @@ function dart {
|
|||||||
wget -O api.mustache https://raw.githubusercontent.com/OpenAPITools/openapi-generator/$OPENAPI_GENERATOR_VERSION/modules/openapi-generator/src/main/resources/dart2/api.mustache
|
wget -O api.mustache https://raw.githubusercontent.com/OpenAPITools/openapi-generator/$OPENAPI_GENERATOR_VERSION/modules/openapi-generator/src/main/resources/dart2/api.mustache
|
||||||
patch --no-backup-if-mismatch -u api.mustache <api.mustache.patch
|
patch --no-backup-if-mismatch -u api.mustache <api.mustache.patch
|
||||||
|
|
||||||
wget -O dart_constructor.mustache https://raw.githubusercontent.com/OpenAPITools/openapi-generator/$OPENAPI_GENERATOR_VERSION/modules/openapi-generator/src/main/resources/dart2/dart_constructor.mustache
|
|
||||||
patch --no-backup-if-mismatch -u dart_constructor.mustache <dart_constructor.mustache.patch
|
|
||||||
|
|
||||||
cd ../../
|
cd ../../
|
||||||
npx --yes @openapitools/openapi-generator-cli generate -g dart -i ./immich-openapi-specs.json -o ../mobile/openapi -t ./templates/mobile
|
npx --yes @openapitools/openapi-generator-cli generate -g dart -i ./immich-openapi-specs.json -o ../mobile/openapi -t ./templates/mobile
|
||||||
|
|
||||||
|
@ -1,10 +0,0 @@
|
|||||||
/// Returns a new [{{{classname}}}] instance.
|
|
||||||
{{{classname}}}({
|
|
||||||
{{#vars}}
|
|
||||||
{{!
|
|
||||||
A field is required in Dart when it is
|
|
||||||
required && !defaultValue in OAS
|
|
||||||
}}
|
|
||||||
{{^isNullable}}{{#required}}{{^defaultValue}}required {{/defaultValue}}{{/required}}{{/isNullable}}this.{{{name}}}{{#isNullable}} = const None(){{/isNullable}}{{^isNullable}}{{#defaultValue}} = {{#isEnum}}{{^isContainer}}const {{{enumName}}}._({{/isContainer}}{{/isEnum}}{{{.}}}{{#isEnum}}{{^isContainer}}){{/isContainer}}{{/isEnum}}{{/defaultValue}}{{/isNullable}},
|
|
||||||
{{/vars}}
|
|
||||||
});
|
|
@ -1,12 +0,0 @@
|
|||||||
diff --git a/dart_constructor.mustache b/dart_constructor.mustache
|
|
||||||
index dc5dfec..4993ab9 100644
|
|
||||||
--- a/dart_constructor.mustache
|
|
||||||
+++ b/dart_constructor.mustache
|
|
||||||
@@ -5,6 +5,6 @@
|
|
||||||
A field is required in Dart when it is
|
|
||||||
required && !defaultValue in OAS
|
|
||||||
}}
|
|
||||||
- {{#required}}{{^defaultValue}}required {{/defaultValue}}{{/required}}this.{{{name}}}{{#defaultValue}} = {{#isEnum}}{{^isContainer}}const {{{enumName}}}._({{/isContainer}}{{/isEnum}}{{{.}}}{{#isEnum}}{{^isContainer}}){{/isContainer}}{{/isEnum}}{{/defaultValue}},
|
|
||||||
+ {{^isNullable}}{{#required}}{{^defaultValue}}required {{/defaultValue}}{{/required}}{{/isNullable}}this.{{{name}}}{{#isNullable}} = const None(){{/isNullable}}{{^isNullable}}{{#defaultValue}} = {{#isEnum}}{{^isContainer}}const {{{enumName}}}._({{/isContainer}}{{/isEnum}}{{{.}}}{{#isEnum}}{{^isContainer}}){{/isContainer}}{{/isEnum}}{{/defaultValue}}{{/isNullable}},
|
|
||||||
{{/vars}}
|
|
||||||
});
|
|
@ -32,7 +32,7 @@ class {{{classname}}} {
|
|||||||
{{/required}}
|
{{/required}}
|
||||||
{{/isNullable}}
|
{{/isNullable}}
|
||||||
{{/isEnum}}
|
{{/isEnum}}
|
||||||
{{#isNullable}}Option<{{/isNullable}}{{{datatypeWithEnum}}}{{#isNullable}}>{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}?{{/defaultValue}}{{/required}}{{/isNullable}} {{{name}}};
|
{{#isNullable}}Option<{{/isNullable}}{{{datatypeWithEnum}}}{{#isNullable}}>?{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}?{{/defaultValue}}{{/required}}{{/isNullable}} {{{name}}};
|
||||||
|
|
||||||
{{/vars}}
|
{{/vars}}
|
||||||
@override
|
@override
|
||||||
@ -45,7 +45,7 @@ class {{{classname}}} {
|
|||||||
int get hashCode =>
|
int get hashCode =>
|
||||||
// ignore: unnecessary_parenthesis
|
// ignore: unnecessary_parenthesis
|
||||||
{{#vars}}
|
{{#vars}}
|
||||||
({{^isNullable}}{{^required}}{{^defaultValue}}{{{name}}} == null ? 0 : {{/defaultValue}}{{/required}}{{/isNullable}}{{{name}}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.hashCode){{^-last}} +{{/-last}}{{#-last}};{{/-last}}
|
({{#isNullable}}{{{name}}} == null ? 0 : {{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}{{{name}}} == null ? 0 : {{/defaultValue}}{{/required}}{{/isNullable}}{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.hashCode){{^-last}} +{{/-last}}{{#-last}};{{/-last}}
|
||||||
{{/vars}}
|
{{/vars}}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@ -55,7 +55,7 @@ class {{{classname}}} {
|
|||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
{{#vars}}
|
{{#vars}}
|
||||||
{{#isNullable}}
|
{{#isNullable}}
|
||||||
if (this.{{{name}}}.unwrapOrNull() != null) {
|
if (this.{{{name}}}?.isSome ?? false) {
|
||||||
{{/isNullable}}
|
{{/isNullable}}
|
||||||
{{^isNullable}}
|
{{^isNullable}}
|
||||||
{{^required}}
|
{{^required}}
|
||||||
@ -67,31 +67,31 @@ class {{{classname}}} {
|
|||||||
{{#isDateTime}}
|
{{#isDateTime}}
|
||||||
{{#pattern}}
|
{{#pattern}}
|
||||||
json[r'{{{baseName}}}'] = _isEpochMarker(r'{{{pattern}}}')
|
json[r'{{{baseName}}}'] = _isEpochMarker(r'{{{pattern}}}')
|
||||||
? this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
? this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
||||||
: this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
: this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
||||||
{{/pattern}}
|
{{/pattern}}
|
||||||
{{^pattern}}
|
{{^pattern}}
|
||||||
json[r'{{{baseName}}}'] = this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
json[r'{{{baseName}}}'] = this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
||||||
{{/pattern}}
|
{{/pattern}}
|
||||||
{{/isDateTime}}
|
{{/isDateTime}}
|
||||||
{{#isDate}}
|
{{#isDate}}
|
||||||
{{#pattern}}
|
{{#pattern}}
|
||||||
json[r'{{{baseName}}}'] = _isEpochMarker(r'{{{pattern}}}')
|
json[r'{{{baseName}}}'] = _isEpochMarker(r'{{{pattern}}}')
|
||||||
? this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
? this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
||||||
: _dateFormatter.format(this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
: _dateFormatter.format(this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
||||||
{{/pattern}}
|
{{/pattern}}
|
||||||
{{^pattern}}
|
{{^pattern}}
|
||||||
json[r'{{{baseName}}}'] = _dateFormatter.format(this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
json[r'{{{baseName}}}'] = _dateFormatter.format(this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
||||||
{{/pattern}}
|
{{/pattern}}
|
||||||
{{/isDate}}
|
{{/isDate}}
|
||||||
{{^isDateTime}}
|
{{^isDateTime}}
|
||||||
{{^isDate}}
|
{{^isDate}}
|
||||||
json[r'{{{baseName}}}'] = this.{{{name}}}{{#isArray}}{{#uniqueItems}}{{#isNullable}}.unwrap(){{/isNullable}}.toList(growable: false){{/uniqueItems}}{{/isArray}};
|
json[r'{{{baseName}}}'] = this.{{{name}}}{{#isArray}}{{#uniqueItems}}{{#isNullable}}!.unwrap(){{/isNullable}}.toList(growable: false){{/uniqueItems}}{{/isArray}};
|
||||||
{{/isDate}}
|
{{/isDate}}
|
||||||
{{/isDateTime}}
|
{{/isDateTime}}
|
||||||
{{#isNullable}}
|
{{#isNullable}}
|
||||||
} else {
|
} else {
|
||||||
if(this.{{{name}}}.isSome) {
|
if(this.{{{name}}}?.isNone ?? false) {
|
||||||
json[r'{{{baseName}}}'] = null;
|
json[r'{{{baseName}}}'] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
diff --git a/native_class.mustache b/native_class.mustache
|
diff --git a/native_class.mustache b/native_class.mustache
|
||||||
index 3a6c457..e321056 100644
|
index 3a6c457..b1c8c5b 100644
|
||||||
--- a/native_class.mustache
|
--- a/native_class.mustache
|
||||||
+++ b/native_class.mustache
|
+++ b/native_class.mustache
|
||||||
@@ -32,7 +32,7 @@ class {{{classname}}} {
|
@@ -32,7 +32,7 @@ class {{{classname}}} {
|
||||||
@ -7,25 +7,16 @@ index 3a6c457..e321056 100644
|
|||||||
{{/isNullable}}
|
{{/isNullable}}
|
||||||
{{/isEnum}}
|
{{/isEnum}}
|
||||||
- {{{datatypeWithEnum}}}{{#isNullable}}?{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}?{{/defaultValue}}{{/required}}{{/isNullable}} {{{name}}};
|
- {{{datatypeWithEnum}}}{{#isNullable}}?{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}?{{/defaultValue}}{{/required}}{{/isNullable}} {{{name}}};
|
||||||
+ {{#isNullable}}Option<{{/isNullable}}{{{datatypeWithEnum}}}{{#isNullable}}>{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}?{{/defaultValue}}{{/required}}{{/isNullable}} {{{name}}};
|
+ {{#isNullable}}Option<{{/isNullable}}{{{datatypeWithEnum}}}{{#isNullable}}>?{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}?{{/defaultValue}}{{/required}}{{/isNullable}} {{{name}}};
|
||||||
|
|
||||||
{{/vars}}
|
{{/vars}}
|
||||||
@override
|
|
||||||
@@ -45,7 +45,7 @@ class {{{classname}}} {
|
|
||||||
int get hashCode =>
|
|
||||||
// ignore: unnecessary_parenthesis
|
|
||||||
{{#vars}}
|
|
||||||
- ({{#isNullable}}{{{name}}} == null ? 0 : {{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}{{{name}}} == null ? 0 : {{/defaultValue}}{{/required}}{{/isNullable}}{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.hashCode){{^-last}} +{{/-last}}{{#-last}};{{/-last}}
|
|
||||||
+ ({{^isNullable}}{{^required}}{{^defaultValue}}{{{name}}} == null ? 0 : {{/defaultValue}}{{/required}}{{/isNullable}}{{{name}}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.hashCode){{^-last}} +{{/-last}}{{#-last}};{{/-last}}
|
|
||||||
{{/vars}}
|
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@@ -55,7 +55,7 @@ class {{{classname}}} {
|
@@ -55,7 +55,7 @@ class {{{classname}}} {
|
||||||
final json = <String, dynamic>{};
|
final json = <String, dynamic>{};
|
||||||
{{#vars}}
|
{{#vars}}
|
||||||
{{#isNullable}}
|
{{#isNullable}}
|
||||||
- if (this.{{{name}}} != null) {
|
- if (this.{{{name}}} != null) {
|
||||||
+ if (this.{{{name}}}.unwrapOrNull() != null) {
|
+ if (this.{{{name}}}?.isSome ?? false) {
|
||||||
{{/isNullable}}
|
{{/isNullable}}
|
||||||
{{^isNullable}}
|
{{^isNullable}}
|
||||||
{{^required}}
|
{{^required}}
|
||||||
@ -35,12 +26,12 @@ index 3a6c457..e321056 100644
|
|||||||
json[r'{{{baseName}}}'] = _isEpochMarker(r'{{{pattern}}}')
|
json[r'{{{baseName}}}'] = _isEpochMarker(r'{{{pattern}}}')
|
||||||
- ? this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
- ? this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
||||||
- : this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
- : this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
||||||
+ ? this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
+ ? this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
||||||
+ : this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
+ : this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
||||||
{{/pattern}}
|
{{/pattern}}
|
||||||
{{^pattern}}
|
{{^pattern}}
|
||||||
- json[r'{{{baseName}}}'] = this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
- json[r'{{{baseName}}}'] = this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
||||||
+ json[r'{{{baseName}}}'] = this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
+ json[r'{{{baseName}}}'] = this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc().toIso8601String();
|
||||||
{{/pattern}}
|
{{/pattern}}
|
||||||
{{/isDateTime}}
|
{{/isDateTime}}
|
||||||
{{#isDate}}
|
{{#isDate}}
|
||||||
@ -48,24 +39,24 @@ index 3a6c457..e321056 100644
|
|||||||
json[r'{{{baseName}}}'] = _isEpochMarker(r'{{{pattern}}}')
|
json[r'{{{baseName}}}'] = _isEpochMarker(r'{{{pattern}}}')
|
||||||
- ? this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
- ? this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
||||||
- : _dateFormatter.format(this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
- : _dateFormatter.format(this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
||||||
+ ? this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
+ ? this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.millisecondsSinceEpoch
|
||||||
+ : _dateFormatter.format(this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
+ : _dateFormatter.format(this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
||||||
{{/pattern}}
|
{{/pattern}}
|
||||||
{{^pattern}}
|
{{^pattern}}
|
||||||
- json[r'{{{baseName}}}'] = _dateFormatter.format(this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
- json[r'{{{baseName}}}'] = _dateFormatter.format(this.{{{name}}}{{#isNullable}}!{{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
||||||
+ json[r'{{{baseName}}}'] = _dateFormatter.format(this.{{{name}}}{{#isNullable}}.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
+ json[r'{{{baseName}}}'] = _dateFormatter.format(this.{{{name}}}{{#isNullable}}!.unwrap(){{/isNullable}}{{^isNullable}}{{^required}}{{^defaultValue}}!{{/defaultValue}}{{/required}}{{/isNullable}}.toUtc());
|
||||||
{{/pattern}}
|
{{/pattern}}
|
||||||
{{/isDate}}
|
{{/isDate}}
|
||||||
{{^isDateTime}}
|
{{^isDateTime}}
|
||||||
{{^isDate}}
|
{{^isDate}}
|
||||||
- json[r'{{{baseName}}}'] = this.{{{name}}}{{#isArray}}{{#uniqueItems}}{{#isNullable}}!{{/isNullable}}.toList(growable: false){{/uniqueItems}}{{/isArray}};
|
- json[r'{{{baseName}}}'] = this.{{{name}}}{{#isArray}}{{#uniqueItems}}{{#isNullable}}!{{/isNullable}}.toList(growable: false){{/uniqueItems}}{{/isArray}};
|
||||||
+ json[r'{{{baseName}}}'] = this.{{{name}}}{{#isArray}}{{#uniqueItems}}{{#isNullable}}.unwrap(){{/isNullable}}.toList(growable: false){{/uniqueItems}}{{/isArray}};
|
+ json[r'{{{baseName}}}'] = this.{{{name}}}{{#isArray}}{{#uniqueItems}}{{#isNullable}}!.unwrap(){{/isNullable}}.toList(growable: false){{/uniqueItems}}{{/isArray}};
|
||||||
{{/isDate}}
|
{{/isDate}}
|
||||||
{{/isDateTime}}
|
{{/isDateTime}}
|
||||||
{{#isNullable}}
|
{{#isNullable}}
|
||||||
} else {
|
} else {
|
||||||
- json[r'{{{baseName}}}'] = null;
|
- json[r'{{{baseName}}}'] = null;
|
||||||
+ if(this.{{{name}}}.isSome) {
|
+ if(this.{{{name}}}?.isNone ?? false) {
|
||||||
+ json[r'{{{baseName}}}'] = null;
|
+ json[r'{{{baseName}}}'] = null;
|
||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user