diff --git a/owncloudComLibrary/src/main/java/com/owncloud/android/lib/resources/files/services/ChunkService.kt b/owncloudComLibrary/src/main/java/com/owncloud/android/lib/resources/files/services/ChunkService.kt index 011dbe35..895b3c14 100644 --- a/owncloudComLibrary/src/main/java/com/owncloud/android/lib/resources/files/services/ChunkService.kt +++ b/owncloudComLibrary/src/main/java/com/owncloud/android/lib/resources/files/services/ChunkService.kt @@ -31,4 +31,12 @@ interface ChunkService : Service { fun removeFile( remotePath: String ): RemoteOperationResult + + fun moveFile( + sourceRemotePath: String, + targetRemotePath: String, + overwrite: Boolean, + fileLastModificationTimestamp: String, + fileLength: Long + ): RemoteOperationResult } diff --git a/owncloudComLibrary/src/main/java/com/owncloud/android/lib/resources/files/services/implementation/OCChunkService.kt b/owncloudComLibrary/src/main/java/com/owncloud/android/lib/resources/files/services/implementation/OCChunkService.kt index d7ca75e8..78068410 100644 --- a/owncloudComLibrary/src/main/java/com/owncloud/android/lib/resources/files/services/implementation/OCChunkService.kt +++ b/owncloudComLibrary/src/main/java/com/owncloud/android/lib/resources/files/services/implementation/OCChunkService.kt @@ -26,6 +26,7 @@ package com.owncloud.android.lib.resources.files.services.implementation import com.owncloud.android.lib.common.OwnCloudClient import com.owncloud.android.lib.common.operations.RemoteOperationResult +import com.owncloud.android.lib.resources.files.chunks.MoveRemoteChunksFileOperation import com.owncloud.android.lib.resources.files.chunks.RemoveRemoteChunksFolderOperation import com.owncloud.android.lib.resources.files.services.ChunkService @@ -33,4 +34,19 @@ class OCChunkService(override val client: OwnCloudClient) : ChunkService { override fun removeFile(remotePath: String): RemoteOperationResult = RemoveRemoteChunksFolderOperation(remotePath = remotePath).execute(client) + + override fun moveFile( + sourceRemotePath: String, + targetRemotePath: String, + overwrite: Boolean, + fileLastModificationTimestamp: String, + fileLength: Long + ): RemoteOperationResult = + MoveRemoteChunksFileOperation( + sourceRemotePath = sourceRemotePath, + targetRemotePath = targetRemotePath, + overwrite = overwrite, + fileLastModificationTimestamp = fileLastModificationTimestamp, + fileLength = fileLength + ).execute(client) }