Class ArArchiveInputStream
java.lang.Object
java.io.InputStream
java.io.FilterInputStream
org.apache.commons.compress.archivers.ArchiveInputStream<ArArchiveEntry>
org.apache.commons.compress.archivers.ar.ArArchiveInputStream
- All Implemented Interfaces:
Closeable, AutoCloseable
Implements the "ar" archive format as an input stream.
-
Field Summary
Fields inherited from class FilterInputStream
in -
Constructor Summary
ConstructorsConstructorDescriptionArArchiveInputStream(InputStream inputStream) Constructs an Ar input stream with the referenced stream -
Method Summary
Methods inherited from class ArchiveInputStream
canReadEntryData, count, count, getBytesRead, getCharset, getCount, mark, markSupported, pushedBackBytes, read, resetMethods inherited from class FilterInputStream
available, read, skipMethods inherited from class InputStream
nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Constructor Details
-
ArArchiveInputStream
Constructs an Ar input stream with the referenced stream- Parameters:
inputStream- the ar input stream
-
-
Method Details
-
matches
Checks if the signature matches ASCII "!<arch>" followed by a single LF control character- Parameters:
signature- the bytes to checklength- the number of bytes to check- Returns:
- true, if this stream is an Ar archive stream, false otherwise
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classFilterInputStream- Throws:
IOException
-
getNextArEntry
Deprecated.UsegetNextEntry().Returns the next AR entry in this stream.- Returns:
- the next AR entry.
- Throws:
IOException- if the entry could not be read
-
getNextEntry
Description copied from class:ArchiveInputStreamGets the next Archive Entry in this Stream.- Specified by:
getNextEntryin classArchiveInputStream<ArArchiveEntry>- Returns:
- the next entry, or
nullif there are no more entries - Throws:
IOException- if the next entry could not be read
-
read
- Overrides:
readin classFilterInputStream- Throws:
IOException
-
getNextEntry().