[英]How to determine if file has changed on the S3 bucket from a mobile client (e.g. iOS)
Is it possible to use AWSS3TransferManager or an alternative class to determine if a file has changed on the s3 server before downloading it? 在下载文件之前,可以使用AWSS3TransferManager或替代类来确定文件在s3服务器上是否已更改?
Ideally I'd like to have some sort of automatic function that takes into account automatically the following: 理想情况下,我希望具有某种自动功能,该功能自动考虑以下内容:
or: 要么:
Alternatively: 或者:
I see that it is possible to get the modification date for an s3 bucket , however I am not sure how this works in iOS. 我看到可以获取s3存储桶的修改日期 ,但是我不确定这在iOS中如何工作。
If you want to download the file like the AWSS3TransferManager download
method, you can use the alternative class AWSS3GetObjectRequest
/ AWSS3GetObjectOutput
. 如果要像AWSS3TransferManager download
方法那样下载文件,则可以使用替代类AWSS3GetObjectRequest
/ AWSS3GetObjectOutput
。
If you do not want to download the file, you can use AWSS3HeadObjectRequest
/ AWSS3HeadObjectOutput
that will return the object's metadata or "head" of the file. 如果你不想下载的文件,你可以使用AWSS3HeadObjectRequest
/ AWSS3HeadObjectOutput
将返回对象的元数据或文件的“头”。
The value: lastModified
will be in the AWSS3...ObjectOutput
value for both class responses. 值: lastModified
将在两个类响应的AWSS3...ObjectOutput
值中。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.