Skip to content

Commit

Permalink
Add missing L for Longs
Browse files Browse the repository at this point in the history
  • Loading branch information
KevinBoulongne committed Sep 6, 2024
1 parent c8c0827 commit 7434cad
Show file tree
Hide file tree
Showing 11 changed files with 44 additions and 44 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,17 +26,17 @@ import io.realm.kotlin.types.annotations.PrimaryKey
class ContainerDB : Container<RealmList<FileDB>>, RealmObject {
@PrimaryKey
override var uuid: String = ""
override var duration: Long = 0
override var createdDateTimestamp: Long = 0
override var expiredDateTimestamp: Long = 0
override var numberOfFile: Long = 0
override var duration: Long = 0L
override var createdDateTimestamp: Long = 0L
override var expiredDateTimestamp: Long = 0L
override var numberOfFile: Long = 0L
override var message: String? = ""
override var needPassword: Long = 0 // TODO: Boolean ?
override var needPassword: Long = 0L // TODO: Boolean ?
override var lang: String = ""
override var sizeUploaded: Long = 0
override var sizeUploaded: Long = 0L
override var deletedDateTimestamp: Long? = null
override var swiftVersion: Long = 0
override var downloadLimit: Long = 0
override var swiftVersion: Long = 0L
override var downloadLimit: Long = 0L
override var source: String = ""

// @SerialName("WSUser") TODO: What's it ?
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ class FileDB : File, RealmObject {
override var containerUUID: String = ""
override var uuid: String = ""
override var fileName: String = ""
override var fileSizeInBytes: Long = 0
override var downloadCounter: Long = 0
override var createdDateTimestamp: Long = 0
override var expiredDateTimestamp: Long = 0
override var fileSizeInBytes: Long = 0L
override var downloadCounter: Long = 0L
override var createdDateTimestamp: Long = 0L
override var expiredDateTimestamp: Long = 0L
override var eVirus: String = ""
override var deletedDate: String? = null
override var mimeType: String = ""
override var receivedSizeInBytes: Long = 0
override var receivedSizeInBytes: Long = 0L
override var path: String? = ""
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ class TransferDB : Transfer<ContainerDB?>, RealmObject {
@PrimaryKey
override var linkUUID: String = ""
override var containerUUID: String = ""
override var downloadCounterCredit: Long = 0
override var createdDateTimestamp: Long = 0
override var expiredDateTimestamp: Long = 0
override var isDownloadOnetime: Long = 0 // TODO: Boolean ?
override var downloadCounterCredit: Long = 0L
override var createdDateTimestamp: Long = 0L
override var expiredDateTimestamp: Long = 0L
override var isDownloadOnetime: Long = 0L // TODO: Boolean ?
override var isMailSent: Boolean = false
override var downloadHost: String = ""
override var container: ContainerDB? = null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@ import io.realm.kotlin.types.RealmObject
* Class representing files to be uploaded
*/
class Upload : RealmObject {
var userId: Long = 0
var userId: Long = 0L
//TODO: implement
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,26 +27,26 @@ class ContainerApi : Container<List<FileApi>> {
@SerialName("UUID")
override var uuid: String = ""

override var duration: Long = 0
override var duration: Long = 0L

@SerialName("createdDate")
@Serializable(DateToTimestampSerializer::class)
override var createdDateTimestamp: Long = 0
override var createdDateTimestamp: Long = 0L

@SerialName("expiredDate")
@Serializable(DateToTimestampSerializer::class)
override var expiredDateTimestamp: Long = 0
override var numberOfFile: Long = 0
override var expiredDateTimestamp: Long = 0L
override var numberOfFile: Long = 0L
override var message: String? = null
override var needPassword: Long = 0
override var needPassword: Long = 0L
override var lang: String = ""
override var sizeUploaded: Long = 0
override var sizeUploaded: Long = 0L

@SerialName("deletedDate")
@Serializable(DateToTimestampSerializer::class)
override var deletedDateTimestamp: Long? = null
override var swiftVersion: Long = 0
override var downloadLimit: Long = 0
override var swiftVersion: Long = 0L
override var downloadLimit: Long = 0L
override var source: String = "ST"

// @SerialName("WSUser") TODO: What's it ?
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,19 @@ class FileApi : File {
@SerialName("UUID")
override var uuid: String = ""
override var fileName: String = ""
override var fileSizeInBytes: Long = 0
override var downloadCounter: Long = 0
override var fileSizeInBytes: Long = 0L
override var downloadCounter: Long = 0L

@SerialName("createdDate")
@Serializable(DateToTimestampSerializer::class)
override var createdDateTimestamp: Long = 0
override var createdDateTimestamp: Long = 0L

@SerialName("expiredDate")
@Serializable(DateToTimestampSerializer::class)
override var expiredDateTimestamp: Long = 0
override var expiredDateTimestamp: Long = 0L
override var eVirus: String = ""
override var deletedDate: String? = null
override var mimeType: String = ""
override var receivedSizeInBytes: Long = 0
override var receivedSizeInBytes: Long = 0L
override var path: String? = null
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,16 @@ import kotlinx.serialization.Serializable
class TransferApi : Transfer<ContainerApi> {
override var linkUUID: String = ""
override var containerUUID: String = ""
override var downloadCounterCredit: Long = 0
override var downloadCounterCredit: Long = 0L

@SerialName("createdDate")
@Serializable(DateToTimestampSerializer::class)
override var createdDateTimestamp: Long = 0
override var createdDateTimestamp: Long = 0L

@SerialName("expiredDate")
@Serializable(DateToTimestampSerializer::class)
override var expiredDateTimestamp: Long = 0
override var isDownloadOnetime: Long = 0
override var expiredDateTimestamp: Long = 0L
override var isDownloadOnetime: Long = 0L

@Serializable(with = IntToBooleanSerializer::class)
override var isMailSent: Boolean = false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@ class InitUploadBody(
val authorEmail: String = "",
val password: String = "",
val message: String = "",
val sizeOfUpload: Long = 0,
val sizeOfUpload: Long = 0L,
val numberOfDownload: Int = 0,
val numberOfFile: Int = 0,
val recaptcha: String = "",
val recaptchaVersion: Long = 0,
val recaptchaVersion: Long = 0L,
val lang: String = "",
val files: List<UploadFileRequest> = emptyList(),
val recipientsEmails: String = "",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ import kotlinx.serialization.Serializable
@Serializable
data class UploadFileRequest(
val name: String = "",
val size: Long = 0,
val size: Long = 0L,
val type: String = "",
)
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ class UploadCompleteResponse(
var linkUUID: String = "",
var containerUUID: String = "",
var userEmail: String? = null,
var downloadCounterCredit: Long = 0,
var downloadCounterCredit: Long = 0L,
@SerialName("createdDate")
@Serializable(DateToTimestampSerializer::class)
var createdDateTimestamp: Long = 0,
var createdDateTimestamp: Long = 0L,
@SerialName("expiredDate")
@Serializable(DateToTimestampSerializer::class)
var expiredDateTimestamp: Long = 0,
var expiredDateTimestamp: Long = 0L,
@Serializable(with = IntToBooleanSerializer::class)
var isDownloadOnetime: Boolean = false,
@Serializable(with = IntToBooleanSerializer::class)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class UploadContainerApi : UploadContainer {
override var uuid: String = ""

override var duration: String = ""
override var downloadLimit: Long = 0
override var downloadLimit: Long = 0L
override var lang: String = ""
override var source: String = ""

Expand All @@ -41,9 +41,9 @@ class UploadContainerApi : UploadContainer {
// var createdDate: String // TODO: Why a complex date instead of a simple date ? May be Custom serial this
@SerialName("expiredDate")
@Serializable(DateToTimestampSerializer::class)
override var expiredDateTimestamp: Long = 0
override var expiredDateTimestamp: Long = 0L
override var needPassword: Boolean = false
override var message: String = ""
@SerialName("numberOfFile")
override var numberOfFiles: Long = 0
override var numberOfFiles: Long = 0L
}

0 comments on commit 7434cad

Please sign in to comment.