@NotThreadSafe public class AlluxioFileOutStream extends FileOutStream
UnderStorageType
is
UnderStorageType.SYNC_PERSIST
, another stream will write the data to the under storage
system.Modifier and Type | Field and Description |
---|---|
protected AlluxioURI |
mUri |
mBytesWritten
Constructor and Description |
---|
AlluxioFileOutStream(AlluxioURI path,
OutStreamOptions options,
FileSystemContext context)
Creates a new file output stream.
|
Modifier and Type | Method and Description |
---|---|
void |
cancel()
Aborts the output stream.
|
void |
close() |
void |
flush() |
void |
write(byte[] b) |
void |
write(byte[] b,
int off,
int len) |
void |
write(int b) |
getBytesWritten
protected final AlluxioURI mUri
public AlluxioFileOutStream(AlluxioURI path, OutStreamOptions options, FileSystemContext context) throws IOException
path
- the file pathoptions
- the client optionscontext
- the file system contextIOException
public void cancel() throws IOException
FileOutStream
cancel
in interface Cancelable
cancel
in class FileOutStream
IOException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class OutputStream
IOException
public void flush() throws IOException
flush
in interface Flushable
flush
in class OutputStream
IOException
public void write(int b) throws IOException
write
in class OutputStream
IOException
public void write(byte[] b) throws IOException
write
in class OutputStream
IOException
public void write(byte[] b, int off, int len) throws IOException
write
in class OutputStream
IOException
Copyright © 2023. All Rights Reserved.