The Object Storage Service (OSS) SDK for Java offers several ways to download objects:
Streaming download (Java SDK V1): You can read object content in real time without saving the entire object to a local file. This method is ideal for processing large objects or performing data operations in memory.
Download to a local file (Java SDK V1): You can download an object and save it to a specified local path for easy management and future use.
Range download (Java SDK V1): You can download a specific part of an object, such as a byte range, instead of the entire object. This is useful when you only need a portion of the object.
Resumable download (Java SDK V1): If a download is interrupted, you can resume it from the breakpoint instead of starting over. This method is ideal for large objects or unstable network conditions because it saves time and bandwidth.
Conditional download (Java SDK V1): You can set specific conditions, such as object size or modification time. The object is downloaded only if these conditions are met. This is useful when you need to ensure the downloaded object meets specific version or status requirements.
Download using a presigned URL (Java SDK V1): You can generate a presigned URL to ensure that only users with a valid signature can access and download the object. This method lets you generate temporary access links for third parties.
During the download, you can also use the progress bar feature to view the download progress.