Class IndexOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- org.apache.jackrabbit.core.query.lucene.directory.IndexOutputStream
-
- All Implemented Interfaces:
Closeable
,Flushable
,AutoCloseable
public class IndexOutputStream extends OutputStream
-
-
Constructor Summary
Constructors Constructor Description IndexOutputStream(IndexOutput output)
Creates a new index output stream and wraps the givenoutput
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
void
flush()
void
write(byte[] b, int off, int len)
void
write(int b)
-
Methods inherited from class java.io.OutputStream
nullOutputStream, write
-
-
-
-
Constructor Detail
-
IndexOutputStream
public IndexOutputStream(IndexOutput output) throws IOException
Creates a new index output stream and wraps the givenoutput
. Bytes will always be written at the end of theoutput
.- Parameters:
output
- the lucene index output.- Throws:
IOException
- if an error occurs while seeking to the end of the indexoutput
.
-
-
Method Detail
-
write
public void write(int b) throws IOException
- Specified by:
write
in classOutputStream
- Throws:
IOException
-
write
public void write(byte[] b, int off, int len) throws IOException
- Overrides:
write
in classOutputStream
- Throws:
IOException
-
flush
public void flush() throws IOException
Flushes the underlying index output.
- Specified by:
flush
in interfaceFlushable
- Overrides:
flush
in classOutputStream
- Throws:
IOException
-
close
public void close() throws IOException
Closes the underlying index output.
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Overrides:
close
in classOutputStream
- Throws:
IOException
-
-