Package com.logicaldoc.util.io
Class AutoDeleteInputStream
java.lang.Object
java.io.InputStream
com.logicaldoc.util.io.AutoDeleteInputStream
- All Implemented Interfaces:
Closeable
,AutoCloseable
Wrapper around a standard InputStream that deletes the file after closing.
- Since:
- 7.7.1
- Author:
- Marco Meschieri - LogicalDOC
-
Constructor Summary
ConstructorDescriptionAutoDeleteInputStream
(File file) AutoDeleteInputStream
(InputStream wrappedStream, File file) -
Method Summary
Methods inherited from class java.io.InputStream
nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Constructor Details
-
AutoDeleteInputStream
- Throws:
FileNotFoundException
-
AutoDeleteInputStream
-
-
Method Details
-
read
- Specified by:
read
in classInputStream
- Throws:
IOException
-
hashCode
public int hashCode() -
read
- Overrides:
read
in classInputStream
- Throws:
IOException
-
equals
-
read
- Overrides:
read
in classInputStream
- Throws:
IOException
-
skip
- Overrides:
skip
in classInputStream
- Throws:
IOException
-
toString
-
available
- Overrides:
available
in classInputStream
- Throws:
IOException
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Overrides:
close
in classInputStream
- Throws:
IOException
-
mark
public void mark(int readlimit) - Overrides:
mark
in classInputStream
-
reset
- Overrides:
reset
in classInputStream
- Throws:
IOException
-
markSupported
public boolean markSupported()- Overrides:
markSupported
in classInputStream
-