archivereaderfactory.html
来自「网络爬虫开源代码」· HTML 代码 · 共 744 行 · 第 1/3 页
HTML
744 行
<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>s</CODE> - Identifying String for this Stream used in error messages. Must be a string that ends with the name of the file we're to put an ArchiveReader on. This code looks at file endings to figure whether to return an ARC or WARC reader.<DD><CODE>is</CODE> - Stream. Stream will be wrapped with implementation of RepositionableStream unless already supported.<DD><CODE>atFirstRecord</CODE> - Are we at first Record?<DT><B>Returns:</B><DD>ArchiveReader.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="asRepositionable(java.io.InputStream)"><!-- --></A><H3>asRepositionable</H3><PRE>protected java.io.InputStream <B>asRepositionable</B>(java.io.InputStream is)</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>is</CODE> - <DT><B>Returns:</B><DD>If passed <code>is</code> is <A HREF="../../../org/archive/io/RepositionableInputStream.html" title="class in org.archive.io"><CODE>RepositionableInputStream</CODE></A>, returns <code>is</code>, else we wrap <code>is</code> with <CODE>RepositionableStream</CODE>.</DL></DD></DL><HR><A NAME="getArchiveReader(java.lang.String, java.io.InputStream, boolean)"><!-- --></A><H3>getArchiveReader</H3><PRE>protected <A HREF="../../../org/archive/io/ArchiveReader.html" title="class in org.archive.io">ArchiveReader</A> <B>getArchiveReader</B>(java.lang.String id, java.io.InputStream is, boolean atFirstRecord) 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="get(java.net.URL, long)"><!-- --></A><H3>get</H3><PRE>public static <A HREF="../../../org/archive/io/ArchiveReader.html" title="class in org.archive.io">ArchiveReader</A> <B>get</B>(java.net.URL u, long offset) throws java.io.IOException</PRE><DL><DD>Get an Archive Reader aligned at <code>offset</code>. This version of get will not bring the file local but will try to stream across the net making an HTTP 1.1 Range request on remote http server (RFC1435 Section 14.35).<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>u</CODE> - HTTP URL for an Archive file.<DD><CODE>offset</CODE> - Offset into file at which to start fetching.<DT><B>Returns:</B><DD>An ArchiveReader aligned at offset.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getArchiveReader(java.net.URL, long)"><!-- --></A><H3>getArchiveReader</H3><PRE>protected <A HREF="../../../org/archive/io/ArchiveReader.html" title="class in org.archive.io">ArchiveReader</A> <B>getArchiveReader</B>(java.net.URL f, long offset) 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="get(java.net.URL)"><!-- --></A><H3>get</H3><PRE>public static <A HREF="../../../org/archive/io/ArchiveReader.html" title="class in org.archive.io">ArchiveReader</A> <B>get</B>(java.net.URL u) throws java.io.IOException</PRE><DL><DD>Get an ARCReader. Pulls the ARC local into whereever the System Property <code>java.io.tmpdir</code> points. It then hands back an ARCReader that points at this local copy. A close on this ARCReader instance will remove the local copy.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>u</CODE> - An URL that points at an ARC.<DT><B>Returns:</B><DD>An ARCReader.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getArchiveReader(java.net.URL)"><!-- --></A><H3>getArchiveReader</H3><PRE>protected <A HREF="../../../org/archive/io/ArchiveReader.html" title="class in org.archive.io">ArchiveReader</A> <B>getArchiveReader</B>(java.net.URL u) 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="makeARCLocal(java.net.URLConnection)"><!-- --></A><H3>makeARCLocal</H3><PRE>protected <A HREF="../../../org/archive/io/ArchiveReader.html" title="class in org.archive.io">ArchiveReader</A> <B>makeARCLocal</B>(java.net.URLConnection connection) 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="addUserAgent(java.net.HttpURLConnection)"><!-- --></A><H3>addUserAgent</H3><PRE>protected void <B>addUserAgent</B>(java.net.HttpURLConnection connection)</PRE><DL><DD><DL></DL></DD><DD><DL></DL></DD></DL><HR><A NAME="isCompressed(java.io.File)"><!-- --></A><H3>isCompressed</H3><PRE>protected boolean <B>isCompressed</B>(java.io.File f) throws java.io.IOException</PRE><DL><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>f</CODE> - File to test.<DT><B>Returns:</B><DD>True if <code>f</code> is compressed.<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> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ArchiveReaderFactory.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD> </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../org/archive/io/ArchiveReader.RandomAccessBufferedInputStream.html" title="class in org.archive.io"><B>PREV CLASS</B></A> <A HREF="../../../org/archive/io/ArchiveRecord.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/ArchiveReaderFactory.html" target="_top"><B>FRAMES</B></A> <A HREF="ArchiveReaderFactory.html" target="_top"><B>NO FRAMES</B></A> <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: NESTED | FIELD | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_bottom"></A><!-- ======== END OF BOTTOM NAVBAR ======= --><HR>Copyright © 2003-2007 Internet Archive. All Rights Reserved.</BODY></HTML>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?