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

📄 assert.html

📁 学习JAVA的很好的JAVA包和文档包
💻 HTML
📖 第 1 页 / 共 2 页
字号:
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html">Object</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#<clinit>()"><clinit></A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#clone()">clone</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#equals(java.lang.Object)">equals</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#finalize()">finalize</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#getClass()">getClass</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#hashCode()">hashCode</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#notify()">notify</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#notifyAll()">notifyAll</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#registerNatives()">registerNatives</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#toString()">toString</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#wait()">wait</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#wait(long)">wait</A>, <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/Object.html#wait(long, int)">wait</A></CODE></TD></TR></TABLE>&nbsp;<P><!-- ============ FIELD DETAIL =========== --><A NAME="field_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Field Detail</B></FONT></TD></TR></TABLE><A NAME="debugLevel"><!-- --></A><H3>debugLevel</H3><PRE>protected static int <B>debugLevel</B></PRE><DL><DD>The current level of debugging; generally 0 upward. A level of 0 is generally considered off.</DL><!-- ========= CONSTRUCTOR DETAIL ======== --><A NAME="constructor_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Constructor Detail</B></FONT></TD></TR></TABLE><A NAME="Assert()"><!-- --></A><H3>Assert</H3><PRE>private <B>Assert</B>()</PRE><DL></DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="debugging()"><!-- --></A><H3>debugging</H3><PRE>public static void <B>debugging</B>()</PRE><DL><DD>Increase the verbosity of the debugging messages.<DD><DL><DT><B>Postcondition:</B><DD>debugging level is increased</DL></DD></DL><HR><A NAME="debugLevel(int)"><!-- --></A><H3>debugLevel</H3><PRE>public static int <B>debugLevel</B>(int&nbsp;level)</PRE><DL><DD>Explictly set the debugging level (0 = none)<DD><DL><DT><B>Parameters:</B><DD><CODE>level</CODE> - the desired level of verosity<DT><B>Precondition:</B><DD>level >= 0<DT><B>Postcondition:</B><DD>the level of debugging is set to <code>level</code><DT><B>Returns:</B><DD>the old level</DL></DD></DL><HR><A NAME="debug(java.lang.String)"><!-- --></A><H3>debug</H3><PRE>public static void <B>debug</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A>&nbsp;message)</PRE><DL><DD>Set up a level 1 debugging message.<DD><DL><DT><B>Parameters:</B><DD><CODE>message</CODE> - a string to be printed if debugging level is 1 or more<DT><B>Postcondition:</B><DD>prints message if the debugging level is 1 or more</DL></DD></DL><HR><A NAME="debug(int, java.lang.String)"><!-- --></A><H3>debug</H3><PRE>public static void <B>debug</B>(int&nbsp;level,                         <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A>&nbsp;message)</PRE><DL><DD>Set up a debugging message at a specific level.<DD><DL><DT><B>Parameters:</B><DD><CODE>level</CODE> - the level that triggers the printing of message<DD><CODE>message</CODE> - the message to be printed at the desired level<DT><B>Precondition:</B><DD>level >= 1 and message is non-null<DT><B>Postcondition:</B><DD>prints message if debugging level is <code>level</code> or more</DL></DD></DL><HR><A NAME="pre(boolean, java.lang.String)"><!-- --></A><H3>pre</H3><PRE>public static void <B>pre</B>(boolean&nbsp;test,                       <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A>&nbsp;message)</PRE><DL><DD>Test a precondition.  If the assertion fails the message indicates that a precondition failed.  A precondition is something you require to be true for the method to be executed correctly.<DD><DL><DT><B>Parameters:</B><DD><CODE>test</CODE> - A boolean expression describing precondition.<DD><CODE>message</CODE> - A string describing precondition.<DT><B>Precondition:</B><DD>Result of precondition test<DT><B>Postcondition:</B><DD>Does nothing if test true, otherwise abort w/message</DL></DD></DL><HR><A NAME="post(boolean, java.lang.String)"><!-- --></A><H3>post</H3><PRE>public static void <B>post</B>(boolean&nbsp;test,                        <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A>&nbsp;message)</PRE><DL><DD>Test a postcondition.  If the assertion fails, the message indicates that a postcondition failed.  A postcondition is something expected to be true after a method invocation, provided the preconditions are met.<DD><DL><DT><B>Parameters:</B><DD><CODE>test</CODE> - A boolean expression describing postcondition.<DD><CODE>message</CODE> - A string describing postcondition.<DT><B>Precondition:</B><DD>Result of postcondition test<DT><B>Postcondition:</B><DD>Does nothing if test true, otherwise abort w/message</DL></DD></DL><HR><A NAME="condition(boolean, java.lang.String)"><!-- --></A><H3>condition</H3><PRE>public static void <B>condition</B>(boolean&nbsp;test,                             <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A>&nbsp;message)</PRE><DL><DD>Test a general condition.  If the assertion fails, the message indicates that a general condition failed.  The condition may be anything that needs to be verified during the course of program execution.<DD><DL><DT><B>Parameters:</B><DD><CODE>test</CODE> - A boolean expression describing the condition.<DD><CODE>message</CODE> - A string describing the condition.<DT><B>Precondition:</B><DD>result of general condition test<DT><B>Postcondition:</B><DD>does nothing if test true, otherwise abort w/message</DL></DD></DL><HR><A NAME="invariant(boolean, java.lang.String)"><!-- --></A><H3>invariant</H3><PRE>public static void <B>invariant</B>(boolean&nbsp;test,                             <A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A>&nbsp;message)</PRE><DL><DD>Test a loop invariant.  If the assertion fails, the message indicates that an invariant failed.  The condition may be anything that needs to be verified during the course of program execution.<DD><DL><DT><B>Parameters:</B><DD><CODE>test</CODE> - A boolean expression describing the condition.<DD><CODE>message</CODE> - A string describing the condition.<DT><B>Precondition:</B><DD>result of an invariant test<DT><B>Postcondition:</B><DD>does nothing if test true, otherwise abort w/message</DL></DD></DL><HR><A NAME="fail(java.lang.String)"><!-- --></A><H3>fail</H3><PRE>public static void <B>fail</B>(<A HREF="http://java.sun.com/j2se/1.3/docs/api/java/lang/String.html">String</A>&nbsp;message)</PRE><DL><DD>Indicate certain failure.  Stops the program with a message indicating why failure occurred.<DD><DL><DT><B>Parameters:</B><DD><CODE>message</CODE> - A string describing the reason for failure.<DT><B>Postcondition:</B><DD>Throws error with message</DL></DD></DL><!-- ========= END OF CLASS DATA ========= --><HR><!-- ========== START OF NAVBAR ========== --><A NAME="navbar_bottom"><!-- --></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0"><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_bottom_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">  <TR ALIGN="center" VALIGN="top">  <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="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><a href=../copyright.html target=_top>&copy; 1998-2002 McGraw-Hill</a></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;<A HREF="../structure/ArrayIterator.html"><B>PREV CLASS</B></A>&nbsp;&nbsp;<A HREF="../structure/Association.html"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../index.html" TARGET="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="Assert.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY: &nbsp;INNER&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><!-- =========== END OF NAVBAR =========== --><HR></BODY></HTML>

⌨️ 快捷键说明

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