public class FLACStreamOutputStream extends Object implements FLACOutputStream, Closeable
| Constructor and Description |
|---|
FLACStreamOutputStream(OutputStream out)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
canSeek()
Test whether this stream is seekable.
|
void |
close()
Close OutputStream owned by this object.
|
long |
getPos()
Get the current write position of this stream.
|
long |
seek(long pos)
Attempt to seek to the given location within this stream.
|
long |
size()
Get the number of bytes that have been written by this object.
|
void |
write(byte data)
Write a byte to this stream.
|
int |
write(byte[] data,
int offset,
int count)
Write the given number of bytes from the byte array.
|
public FLACStreamOutputStream(OutputStream out) throws IOException
out - OutputStream to write the FLAC stream to.IOExceptionpublic long seek(long pos)
seek in interface FLACOutputStreampos - target position to seek to.public void write(byte data)
throws IOException
write in interface FLACOutputStreamdata - byte to write.IOException - IOException will be raised if an error occurred while
writing.public int write(byte[] data,
int offset,
int count)
throws IOException
write in interface FLACOutputStreamdata - array containing bytes to be written.offset - start index of array to begin reading from.count - number of bytes to write.IOException - IOException upon a write error.public long size()
size in interface FLACOutputStreampublic boolean canSeek()
canSeek in interface FLACOutputStreampublic long getPos()
getPos in interface FLACOutputStreampublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in interface FLACOutputStreamIOExceptionCopyright © 2017. All rights reserved.