Download a file from the folder
Note: Catalyst now offers you a brand new object storage component called Stratus in Early Access mode. This component is a significant upgrade to the current Cloud Scale File Store component. You can find out more about the Stratus component here.
To use the Stratus component in the Early Access mode, email us at support@zohocatalyst.com.
To use the Stratus component in the Early Access mode, email us at support@zohocatalyst.com.
You can download a file from the folder by referring to its unique File ID. The input stream of the file is obtained by calling the downloadFile() method.
Ensure the following packages are imported:
copy
import com.zc.component.files.ZCFile;
import com.zc.component.files.ZCFolder;
copy
//Get an instance for the file store
ZCFile fileStore = ZCFile.getInstance();
//Get Folder details using folder ID
ZCFolder folder = fileStore.getFolderInstance(1510000000109393L);
//Download the File as an Input Stream using the file id
InputStream is = folder.downloadFile(1510000000108418L);
Last Updated 2025-02-24 14:38:44 +0530 +0530
Yes
No
Send your feedback to us
Skip
Submit