Class DownloadStreamConfig
- java.lang.Object
-
- net.snowflake.client.api.connection.DownloadStreamConfig
-
public class DownloadStreamConfig extends Object
Optional configuration for downloading files from a Snowflake stage as a stream.This class provides optional configuration for the
SnowflakeConnection.downloadStream(String, String, DownloadStreamConfig)method. Required parameters (stageName, sourceFileName) are passed as method arguments, while optional settings are configured here.Example usage:
DownloadStreamConfig config = DownloadStreamConfig.builder() .setDecompress(true) .build(); try (InputStream stream = connection.downloadStream("@my_stage", "data/file.csv.gz", config)) { // Process the stream }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classDownloadStreamConfig.BuilderBuilder for creatingDownloadStreamConfiginstances.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static DownloadStreamConfig.Builderbuilder()Creates a new builder instance.booleanisDecompress()Whether to decompress the file during download.StringtoString()
-
-
-
Method Detail
-
isDecompress
public boolean isDecompress()
Whether to decompress the file during download.- Returns:
- true if the file should be decompressed, false otherwise
-
builder
public static DownloadStreamConfig.Builder builder()
Creates a new builder instance.- Returns:
- a new
DownloadStreamConfig.Builder
-
-