recordingoutputstream.html

来自「网络爬虫开源代码」· HTML 代码 · 共 1,143 行 · 第 1/3 页

HTML
1,143
字号
<A NAME="flush()"><!-- --></A><H3>flush</H3><PRE>public void <B>flush</B>()           throws java.io.IOException</PRE><DL><DD><DL><DT><B>Specified by:</B><DD><CODE>flush</CODE> in interface <CODE>java.io.Flushable</CODE><DT><B>Overrides:</B><DD><CODE>flush</CODE> in class <CODE>java.io.OutputStream</CODE></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getReplayInputStream()"><!-- --></A><H3>getReplayInputStream</H3><PRE>public <A HREF="../../../org/archive/io/ReplayInputStream.html" title="class in org.archive.io">ReplayInputStream</A> <B>getReplayInputStream</B>()                                       throws java.io.IOException</PRE><DL><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getReplayInputStream(long)"><!-- --></A><H3>getReplayInputStream</H3><PRE>public <A HREF="../../../org/archive/io/ReplayInputStream.html" title="class in org.archive.io">ReplayInputStream</A> <B>getReplayInputStream</B>(long&nbsp;skip)                                       throws java.io.IOException</PRE><DL><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getContentReplayInputStream()"><!-- --></A><H3>getContentReplayInputStream</H3><PRE>public <A HREF="../../../org/archive/io/ReplayInputStream.html" title="class in org.archive.io">ReplayInputStream</A> <B>getContentReplayInputStream</B>()                                              throws java.io.IOException</PRE><DL><DD>Return a replay stream, cued up to begining of content<P><DD><DL><DT><B>Returns:</B><DD>An RIS.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getSize()"><!-- --></A><H3>getSize</H3><PRE>public long <B>getSize</B>()</PRE><DL><DD><DL></DL></DD></DL><HR><A NAME="markContentBegin()"><!-- --></A><H3>markContentBegin</H3><PRE>public void <B>markContentBegin</B>()</PRE><DL><DD>Remember the current position as the start of the "response body". Useful when recording HTTP traffic as a way to start replays after the headers.<P><DD><DL></DL></DD></DL><HR><A NAME="getContentBegin()"><!-- --></A><H3>getContentBegin</H3><PRE>public long <B>getContentBegin</B>()</PRE><DL><DD>Return stored content-begin-mark (which is also end-of-headers)<P><DD><DL></DL></DD></DL><HR><A NAME="startDigest()"><!-- --></A><H3>startDigest</H3><PRE>public void <B>startDigest</B>()</PRE><DL><DD>Starts digesting recorded data, if a MessageDigest has been set.<P><DD><DL></DL></DD></DL><HR><A NAME="setSha1Digest()"><!-- --></A><H3>setSha1Digest</H3><PRE>public void <B>setSha1Digest</B>()</PRE><DL><DD>Convenience method for setting SHA1 digest.<P><DD><DL><DT><B>See Also:</B><DD><A HREF="../../../org/archive/io/RecordingOutputStream.html#setDigest(java.lang.String)"><CODE>setDigest(String)</CODE></A></DL></DD></DL><HR><A NAME="setDigest(java.lang.String)"><!-- --></A><H3>setDigest</H3><PRE>public void <B>setDigest</B>(java.lang.String&nbsp;algorithm)</PRE><DL><DD>Sets a digest function which may be applied to recorded data. The difference between calling this method and <A HREF="../../../org/archive/io/RecordingOutputStream.html#setDigest(java.security.MessageDigest)"><CODE>setDigest(MessageDigest)</CODE></A> is that this method tries to reuse MethodDigest instance if already allocated and of appropriate algorithm.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>algorithm</CODE> - Message digest algorithm to use.<DT><B>See Also:</B><DD><A HREF="../../../org/archive/io/RecordingOutputStream.html#setDigest(java.security.MessageDigest)"><CODE>setDigest(MessageDigest)</CODE></A></DL></DD></DL><HR><A NAME="setDigest(java.security.MessageDigest)"><!-- --></A><H3>setDigest</H3><PRE>public void <B>setDigest</B>(java.security.MessageDigest&nbsp;md)</PRE><DL><DD>Sets a digest function which may be applied to recorded data. As usually only a subset of the recorded data should be fed to the digest, you must also call startDigest() to begin digesting.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>md</CODE> - Message digest function to use.</DL></DD></DL><HR><A NAME="getDigestValue()"><!-- --></A><H3>getDigestValue</H3><PRE>public byte[] <B>getDigestValue</B>()</PRE><DL><DD>Return the digest value for any recorded, digested data. Call only after all data has been recorded; otherwise, the running digest state is ruined.<P><DD><DL><DT><B>Returns:</B><DD>the digest final value</DL></DD></DL><HR><A NAME="getReplayCharSequence()"><!-- --></A><H3>getReplayCharSequence</H3><PRE>public <A HREF="../../../org/archive/io/ReplayCharSequence.html" title="interface in org.archive.io">ReplayCharSequence</A> <B>getReplayCharSequence</B>()                                         throws java.io.IOException</PRE><DL><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getReplayCharSequence(java.lang.String)"><!-- --></A><H3>getReplayCharSequence</H3><PRE>public <A HREF="../../../org/archive/io/ReplayCharSequence.html" title="interface in org.archive.io">ReplayCharSequence</A> <B>getReplayCharSequence</B>(java.lang.String&nbsp;characterEncoding)                                         throws java.io.IOException</PRE><DL><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getReplayCharSequence(java.lang.String, long)"><!-- --></A><H3>getReplayCharSequence</H3><PRE>public <A HREF="../../../org/archive/io/ReplayCharSequence.html" title="interface in org.archive.io">ReplayCharSequence</A> <B>getReplayCharSequence</B>(java.lang.String&nbsp;characterEncoding,                                                long&nbsp;startOffset)                                         throws java.io.IOException</PRE><DL><DD><DL><DT><B>Parameters:</B><DD><CODE>characterEncoding</CODE> - Encoding of recorded stream.<DT><B>Returns:</B><DD>A ReplayCharSequence  Will return null if an IOException.  Call close on returned RCS when done.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="getResponseContentLength()"><!-- --></A><H3>getResponseContentLength</H3><PRE>public long <B>getResponseContentLength</B>()</PRE><DL><DD><DL></DL></DD></DL><HR><A NAME="isOpen()"><!-- --></A><H3>isOpen</H3><PRE>public boolean <B>isOpen</B>()</PRE><DL><DD><DL><DT><B>Returns:</B><DD>True if this ROS is open.</DL></DD></DL><HR><A NAME="mark()"><!-- --></A><H3>mark</H3><PRE>public void <B>mark</B>()</PRE><DL><DD>When used alongside a mark-supporting RecordingInputStream, remember a position reachable by a future reset().<P><DD><DL></DL></DD></DL><HR><A NAME="reset()"><!-- --></A><H3>reset</H3><PRE>public void <B>reset</B>()</PRE><DL><DD>When used alongside a mark-supporting RecordingInputStream, reset  the position to that saved by previous mark(). Until the position  again reached "new" material, none of the bytes pushed to this  stream will be digested or recorded.<P><DD><DL></DL></DD></DL><HR><A NAME="setLimits(long, long, long)"><!-- --></A><H3>setLimits</H3><PRE>public void <B>setLimits</B>(long&nbsp;length,                      long&nbsp;milliseconds,                      long&nbsp;rateKBps)</PRE><DL><DD>Set limits on length, time, and rate to enforce.<P><DD><DL><DT><B>Parameters:</B><DD><CODE>length</CODE> - <DD><CODE>milliseconds</CODE> - <DD><CODE>rateKBps</CODE> - </DL></DD></DL><HR><A NAME="resetLimits()"><!-- --></A><H3>resetLimits</H3><PRE>public void <B>resetLimits</B>()</PRE><DL><DD>Reset limits to effectively-unlimited defaults<P><DD><DL></DL></DD></DL><HR><A NAME="getRemainingLength()"><!-- --></A><H3>getRemainingLength</H3><PRE>public long <B>getRemainingLength</B>()</PRE><DL><DD>Return number of bytes that could be recorded without hitting  length limit<P><DD><DL><DT><B>Returns:</B><DD>long byte count</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/RecordingOutputStream.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/RecordingInputStream.html" title="class in org.archive.io"><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../../../org/archive/io/RecoverableIOException.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/RecordingOutputStream.html" target="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="RecordingOutputStream.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="#field_summary">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;<A HREF="#field_detail">FIELD</A>&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-2007 Internet Archive. All Rights Reserved.</BODY></HTML>

⌨️ 快捷键说明

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