Package org.wildfly.security.util
Class AtomicFileOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- org.wildfly.security.util.AtomicFileOutputStream
-
- All Implemented Interfaces:
Closeable,Flushable,AutoCloseable
public final class AtomicFileOutputStream extends OutputStream
- Author:
- David M. Lloyd
-
-
Constructor Summary
Constructors Constructor Description AtomicFileOutputStream(File file)AtomicFileOutputStream(String name)AtomicFileOutputStream(Path path)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcancel()voidclose()voidflush()voidwrite(byte[] bytes, int off, int len)voidwrite(int b)-
Methods inherited from class java.io.OutputStream
nullOutputStream, write
-
-
-
-
Constructor Detail
-
AtomicFileOutputStream
public AtomicFileOutputStream(String name) throws IOException
- Throws:
IOException
-
AtomicFileOutputStream
public AtomicFileOutputStream(File file) throws IOException
- Throws:
IOException
-
AtomicFileOutputStream
public AtomicFileOutputStream(Path path) throws IOException
- Throws:
IOException
-
-
Method Detail
-
flush
public void flush() throws IOException- Specified by:
flushin interfaceFlushable- Overrides:
flushin classOutputStream- Throws:
IOException
-
close
public void close() throws IOException- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classOutputStream- Throws:
IOException
-
write
public void write(int b) throws IOException- Specified by:
writein classOutputStream- Throws:
IOException
-
write
public void write(byte[] bytes, int off, int len) throws IOException- Overrides:
writein classOutputStream- Throws:
IOException
-
cancel
public void cancel() throws IOException- Throws:
IOException
-
-