?? recordinginputstream.html
字號:
</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> int</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#read(byte[], int, int)">read</A></B>(byte[] b, int off, int len)</CODE><BR> </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> long</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#readFully()">readFully</A></B>()</CODE><BR> </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#readFullyOrUntil(long)">readFullyOrUntil</A></B>(long softMaxLength)</CODE><BR> Read all of a stream (Or read until we timeout or have read to the max).</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#reset()">reset</A></B>()</CODE><BR> </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#setDigest(java.security.MessageDigest)">setDigest</A></B>(java.security.MessageDigest md)</CODE><BR> Sets a digest function which may be applied to recorded data.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#setDigest(java.lang.String)">setDigest</A></B>(java.lang.String algorithm)</CODE><BR> Sets a digest algorithm which may be applied to recorded data.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#setLimits(long, long, long)">setLimits</A></B>(long hardMax, long timeoutMs, long maxRateKBps)</CODE><BR> Set limits to be enforced by internal recording-out</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#setSha1Digest()">setSha1Digest</A></B>()</CODE><BR> Convenience method for setting SHA1 digest.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B><A HREF="../../../org/archive/io/RecordingInputStream.html#startDigest()">startDigest</A></B>()</CODE><BR> </TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.io.InputStream"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TH ALIGN="left"><B>Methods inherited from class java.io.InputStream</B></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE>available, skip</CODE></TD></TR></TABLE> <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD></TR></TABLE> <P><!-- ============ FIELD DETAIL =========== --><A NAME="field_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>Field Detail</B></FONT></TH></TR></TABLE><A NAME="logger"><!-- --></A><H3>logger</H3><PRE>protected static java.util.logging.Logger <B>logger</B></PRE><DL><DL></DL></DL><HR><A NAME="drainBuffer"><!-- --></A><H3>drainBuffer</H3><PRE>protected byte[] <B>drainBuffer</B></PRE><DL><DD>Reusable buffer to avoid reallocation on each readFullyUntil<P><DL></DL></DL><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_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>Constructor Detail</B></FONT></TH></TR></TABLE><A NAME="RecordingInputStream(int, java.lang.String)"><!-- --></A><H3>RecordingInputStream</H3><PRE>public <B>RecordingInputStream</B>(int bufferSize, java.lang.String backingFilename)</PRE><DL><DD>Create a new RecordingInputStream.<P><DL><DT><B>Parameters:</B><DD><CODE>bufferSize</CODE> - Size of buffer to use.<DD><CODE>backingFilename</CODE> - Name of backing file.</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="open(java.io.InputStream)"><!-- --></A><H3>open</H3><PRE>public void <B>open</B>(java.io.InputStream wrappedStream) throws java.io.IOException</PRE><DL><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="read()"><!-- --></A><H3>read</H3><PRE>public int <B>read</B>() throws java.io.IOException</PRE><DL><DD><DL><DT><B>Specified by:</B><DD><CODE>read</CODE> in class <CODE>java.io.InputStream</CODE></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="read(byte[], int, int)"><!-- --></A><H3>read</H3><PRE>public int <B>read</B>(byte[] b, int off, int len) throws java.io.IOException</PRE><DL><DD><DL><DT><B>Overrides:</B><DD><CODE>read</CODE> in class <CODE>java.io.InputStream</CODE></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="read(byte[])"><!-- --></A><H3>read</H3><PRE>public int <B>read</B>(byte[] b) throws java.io.IOException</PRE><DL><DD><DL><DT><B>Overrides:</B><DD><CODE>read</CODE> in class <CODE>java.io.InputStream</CODE></DL></DD><DD><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="close()"><!-- --></A><H3>close</H3><PRE>public void <B>close</B>() throws java.io.IOException</PRE><DL><DD><DL><DT><B>Specified by:</B><DD><CODE>close</CODE> in interface <CODE>java.io.Closeable</CODE><DT><B>Overrides:</B><DD><CODE>close</CODE> in class <CODE>java.io.InputStream</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="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><DL><DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE></DL></DD></DL><HR><A NAME="readFully()"><!-- --></A><H3>readFully</H3><PRE>public long <B>readFully</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="readFullyOrUntil(long)"><!-- --></A><H3>readFullyOrUntil</H3><PRE>public void <B>readFullyOrUntil</B>(long softMaxLength) throws java.io.IOException, <A HREF="../../../org/archive/io/RecorderLengthExceededException.html" title="class in org.archive.io">RecorderLengthExceededException</A>, <A HREF="../../../org/archive/io/RecorderTimeoutException.html" title="class in org.archive.io">RecorderTimeoutException</A>, java.lang.InterruptedException</PRE><DL><DD>Read all of a stream (Or read until we timeout or have read to the max).<P><DD><DL><DT><B>Parameters:</B><DD><CODE>softMaxLength</CODE> - Maximum length to read; if zero or < 0, then no limit. If met, return normally.<DD><CODE>hardMaxLength</CODE> - Maximum length to read; if zero or < 0, then no limit. If exceeded, throw RecorderLengthExceededException<DD><CODE>timeout</CODE> - Timeout in milliseconds for total read; if zero or negative, timeout is <code>Long.MAX_VALUE</code>. If exceeded, throw RecorderTimeoutException<DD><CODE>maxBytesPerMs</CODE> - How many bytes per millisecond.<DT><B>Throws:</B><DD><CODE>java.io.IOException</CODE> - failed read.<DD><CODE><A HREF="../../../org/archive/io/RecorderLengthExceededException.html" title="class in org.archive.io">RecorderLengthExceededException</A></CODE><DD><CODE><A HREF="../../../org/archive/io/RecorderTimeoutException.html" title="class in org.archive.io">RecorderTimeoutException</A></CODE><DD><CODE>java.lang.InterruptedException</CODE></DL></DD></DL>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -