⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gzippedinputstream.html

📁 用JAVA编写的,在做实验的时候留下来的,本来想删的,但是传上来,大家分享吧
💻 HTML
📖 第 1 页 / 共 2 页
字号:
<A NAME="GzippedInputStream(java.io.InputStream, int)"><!-- --></A><H3>GzippedInputStream</H3><PRE>public <B>GzippedInputStream</B>(java.io.InputStream&nbsp;is,                          int&nbsp;size)                   throws java.io.IOException</PRE><DL><DL><DT><B>Parameters:</B><DD><CODE>is</CODE> - An InputStream that implements RespositionableStream and returns <code>true</code> when we call <CODE>InputStream.markSupported()</CODE> (Latter is needed so can setup an <CODE>Iterator</CODE> against the Gzip stream).<DD><CODE>size</CODE> - Size of blocks to use reading.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"><B>Method Detail</B></FONT></TH></TR></TABLE><A NAME="checkStream(java.io.InputStream)"><!-- --></A><H3>checkStream</H3><PRE>protected static java.io.InputStream <B>checkStream</B>(java.io.InputStream&nbsp;is)                                          throws java.io.IOException</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="gotoEOR(int)"><!-- --></A><H3>gotoEOR</H3><PRE>public long <B>gotoEOR</B>(int&nbsp;ignore)             throws java.io.IOException</PRE><DL><DD>Exhaust current GZIP member content. Call this method when you think you're on the end of the GZIP member.  It will clean out any dross.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>ignore</CODE> - Character to ignore counting characters (Usually trailing new lines).<DT><B>Returns:</B><DD>Count of characters skipped over.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="gotoEOR()"><!-- --></A><H3>gotoEOR</H3><PRE>public long <B>gotoEOR</B>()             throws java.io.IOException</PRE><DL><DD>Exhaust current GZIP member content. Call this method when you think you're on the end of the GZIP member.  It will clean out any dross.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>Count of characters skipped over.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="iterator()"><!-- --></A><H3>iterator</H3><PRE>public java.util.Iterator <B>iterator</B>()</PRE><DL><DD>Returns a GZIP Member Iterator. Has limitations. Can only get one Iterator per instance of this class; you must get new instance if you want to get Iterator again.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>Iterator over GZIP Members.</DL></DD></DL><HR><A NAME="moveToNextGzipMember()"><!-- --></A><H3>moveToNextGzipMember</H3><PRE>protected boolean <B>moveToNextGzipMember</B>()</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>True if we found another record in the stream.</DL></DD></DL><HR><A NAME="getInflater()"><!-- --></A><H3>getInflater</H3><PRE>protected java.util.zip.Inflater <B>getInflater</B>()</PRE><DL><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="getInputStream()"><!-- --></A><H3>getInputStream</H3><PRE>protected java.io.InputStream <B>getInputStream</B>()</PRE><DL><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="getGzipHeader()"><!-- --></A><H3>getGzipHeader</H3><PRE>protected <A HREF="../../../org/archive/io/GzipHeader.html" title="class in org.archive.io">GzipHeader</A> <B>getGzipHeader</B>()</PRE><DL><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="resetInflater()"><!-- --></A><H3>resetInflater</H3><PRE>protected void <B>resetInflater</B>()</PRE><DL><DD>Move to next gzip member in the file.<P><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="readHeader()"><!-- --></A><H3>readHeader</H3><PRE>protected void <B>readHeader</B>()                   throws java.io.IOException</PRE><DL><DD>Read in the gzip header.<P><DD><DL></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="position(long)"><!-- --></A><H3>position</H3><PRE>public void <B>position</B>(long&nbsp;position)              throws java.io.IOException</PRE><DL><DD>Seek to passed offset.  After positioning the stream, it resets the inflater. Assumption is that public use of this method is only to position stream at start of a gzip member.<P><DD><DL><DT><B>Specified by:</B><DD><CODE>position</CODE> in interface <CODE>it.unimi.dsi.fastutil.io.RepositionableStream</CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>position</CODE> - Absolute position of a gzip member start.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="position()"><!-- --></A><H3>position</H3><PRE>public long <B>position</B>()              throws java.io.IOException</PRE><DL><DD><DL><DT><B>Specified by:</B><DD><CODE>position</CODE> in interface <CODE>it.unimi.dsi.fastutil.io.RepositionableStream</CODE></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="gzipMemberSeek(long)"><!-- --></A><H3>gzipMemberSeek</H3><PRE>public void <B>gzipMemberSeek</B>(long&nbsp;position)                    throws java.io.IOException</PRE><DL><DD>Seek to a gzip member.  Moves stream to new position, resets inflater and reads in the gzip header ready for subsequent calls to read.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>position</CODE> - Absolute position of a gzip member start.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="gzipMemberSeek()"><!-- --></A><H3>gzipMemberSeek</H3><PRE>public void <B>gzipMemberSeek</B>()                    throws java.io.IOException</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="gzip(byte[])"><!-- --></A><H3>gzip</H3><PRE>public static byte[] <B>gzip</B>(byte[]&nbsp;bytes)                   throws java.io.IOException</PRE><DL><DD>Gzip passed bytes. Use only when bytes is small.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>bytes</CODE> - What to gzip.<DT><B>Returns:</B><DD>A gzip member of bytes.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="isCompressedRepositionableStream(it.unimi.dsi.fastutil.io.RepositionableStream)"><!-- --></A><H3>isCompressedRepositionableStream</H3><PRE>public static boolean <B>isCompressedRepositionableStream</B>(it.unimi.dsi.fastutil.io.RepositionableStream&nbsp;rs)                                                throws java.io.IOException</PRE><DL><DD>Tests passed stream is GZIP stream by reading in the HEAD. Does reposition of stream when done.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>rs</CODE> - An InputStream that is Repositionable.<DT><B>Returns:</B><DD>True if compressed stream.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="isCompressedStream(java.io.InputStream)"><!-- --></A><H3>isCompressedStream</H3><PRE>public static boolean <B>isCompressedStream</B>(java.io.InputStream&nbsp;is)                                  throws java.io.IOException</PRE><DL><DD>Tests passed stream is gzip stream by reading in the HEAD. Does not reposition stream when done.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>is</CODE> - An InputStream.<DT><B>Returns:</B><DD>True if compressed stream.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ======= START OF BOTTOM NAVBAR ====== --><A NAME="navbar_bottom"><!-- --></A><A HREF="#skip-navbar_bottom" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/GzippedInputStream.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../../../org/archive/io/GzipHeader.html" title="class in org.archive.io"><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../../../org/archive/io/NoGzipMagicException.html" title="class in org.archive.io"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../../index.html?org/archive/io/GzippedInputStream.html" target="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="GzippedInputStream.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;&nbsp;<SCRIPT type="text/javascript">  <!--  if(window==top) {    document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');  }  //--></SCRIPT><NOSCRIPT>  <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#fields_inherited_from_class_java.util.zip.GZIPInputStream">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR>Copyright &copy; 2003-2006 Internet Archive. All Rights Reserved.</BODY></HTML>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -