commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r759426 - /commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveInputStream.java
Date Sat, 28 Mar 2009 03:31:43 GMT
Author: sebb
Date: Sat Mar 28 03:31:42 2009
New Revision: 759426

URL: http://svn.apache.org/viewvc?rev=759426&view=rev
Log:
Javadoc

Modified:
    commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveInputStream.java

Modified: commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveInputStream.java
URL: http://svn.apache.org/viewvc/commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveInputStream.java?rev=759426&r1=759425&r2=759426&view=diff
==============================================================================
--- commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveInputStream.java
(original)
+++ commons/proper/compress/trunk/src/main/java/org/apache/commons/compress/archivers/ArchiveInputStream.java
Sat Mar 28 03:31:42 2009
@@ -21,6 +21,21 @@
 import java.io.IOException;
 import java.io.InputStream;
 
+/**
+ * Archive input streams are expected to override the<br/>
+ * {@link #read()} and {@link #read(byte[] b, int off, int len)} <br/>
+ * methods so that reading from the stream generates EOF for the end of
+ * data in each entry as well as at the end of the file proper. The
+ * {@link #getNextEntry()} method is used to reset the input stream
+ * ready for reading the data from the next entry.
+ * <p>
+ * The input stream classes must also implement a method with the signature:
+ * <pre>
+ * public static boolean matches(byte[] signature, int length)
+ * </pre>
+ * which is used by the {@link ArchiveStreamFactory} to autodetect
+ * the archive type from the first few bytes of a stream. 
+ */
 public abstract class ArchiveInputStream extends InputStream {
 
     /**



Mime
View raw message