public class S3InputFile extends java.lang.Object implements InputFile, NativelyEncryptedFile
Modifier and Type | Method and Description |
---|---|
boolean |
exists()
Note: this may be stale if file was deleted since metadata is cached for size/existence checks.
|
static S3InputFile |
fromLocation(java.lang.String location,
long length,
software.amazon.awssdk.services.s3.S3Client client,
S3FileIOProperties s3FileIOProperties,
MetricsContext metrics) |
static S3InputFile |
fromLocation(java.lang.String location,
software.amazon.awssdk.services.s3.S3Client client,
S3FileIOProperties s3FileIOProperties,
MetricsContext metrics) |
long |
getLength()
Note: this may be stale if file was deleted since metadata is cached for size/existence checks.
|
protected software.amazon.awssdk.services.s3.model.HeadObjectResponse |
getObjectMetadata() |
java.lang.String |
location() |
protected MetricsContext |
metrics() |
NativeFileCryptoParameters |
nativeCryptoParameters() |
SeekableInputStream |
newStream()
Opens a new
SeekableInputStream for the underlying data file |
S3FileIOProperties |
s3FileIOProperties() |
void |
setNativeCryptoParameters(NativeFileCryptoParameters nativeCryptoParameters) |
java.lang.String |
toString() |
public static S3InputFile fromLocation(java.lang.String location, software.amazon.awssdk.services.s3.S3Client client, S3FileIOProperties s3FileIOProperties, MetricsContext metrics)
public static S3InputFile fromLocation(java.lang.String location, long length, software.amazon.awssdk.services.s3.S3Client client, S3FileIOProperties s3FileIOProperties, MetricsContext metrics)
public long getLength()
public SeekableInputStream newStream()
InputFile
SeekableInputStream
for the underlying data filepublic NativeFileCryptoParameters nativeCryptoParameters()
nativeCryptoParameters
in interface NativelyEncryptedFile
public void setNativeCryptoParameters(NativeFileCryptoParameters nativeCryptoParameters)
setNativeCryptoParameters
in interface NativelyEncryptedFile
public java.lang.String location()
public S3FileIOProperties s3FileIOProperties()
protected MetricsContext metrics()
public boolean exists()
protected software.amazon.awssdk.services.s3.model.HeadObjectResponse getObjectMetadata() throws software.amazon.awssdk.services.s3.model.S3Exception
software.amazon.awssdk.services.s3.model.S3Exception
public java.lang.String toString()
toString
in class java.lang.Object