Bug=81699

author=ashuk
r=edburns

Files modified

M util/classes/org/mozilla/util/Assert.java
M webclient/classes_spec/org/mozilla/webclient/BrowserControlCanvas.java
M webclient/classes_spec/org/mozilla/webclient/BrowserControlFactory.java
M webclient/classes_spec/org/mozilla/webclient/BrowserControlImpl.java
M webclient/classes_spec/org/mozilla/webclient/test/EMWindow.java
M webclient/classes_spec/org/mozilla/webclient/test/RandomHTMLInputStream.java
M webclient/classes_spec/org/mozilla/webclient/test/UniversalDialog.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/BookmarksImpl.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/CurrentPageImpl.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/EventRegistrationImpl.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/HistoryImpl.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/NativeEventThread.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/NavigationImpl.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/PreferencesImpl.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/RDFEnumeration.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/RDFTreeNode.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/WCMouseListenerImpl.java
M webclient/classes_spec/org/mozilla/webclient/wrapper_native/WindowControlImpl.java


This fix changes the name of the Assert.assert methd to Assert.assert_it
in all the Blackwood modules which use this Assertion facility from
java/util. This is necessary for getting Blackwood to work with JDK1.4
since assert is a keyword in JDK1.4 onwards.


git-svn-id: svn://10.0.0.236/trunk@96003 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
ashuk%eng.sun.com
2001-05-29 18:36:13 +00:00
parent 5c201ad740
commit f13d42e2da
18 changed files with 101 additions and 101 deletions

View File

@@ -34,7 +34,7 @@ package org.mozilla.util;
*
* Typical usage:
* <BLOCKQUOTE><TT>
* Assert.assert(Assert.enabled && mytest(), "my test failed");
* Assert.assert_it(Assert.enabled && mytest(), "my test failed");
* </TT></BLOCKQUOTE><P>
*
* Such usage prevents <TT>mytest()</TT> from being executed if assertions
@@ -45,19 +45,19 @@ package org.mozilla.util;
* If you know that the condition being tested is fast, you may omit the
* <I>enabled</I> flag:
* <BLOCKQUOTE><TT>
* Assert.assert(myValue != null);
* Assert.assert_it(myValue != null);
* </TT></BLOCKQUOTE><P>
*
* Note that even in this second usage, if assertions are disabled,
* the <B>assert()</B> method will do nothing.<P>
* the <B>assert_it()</B> method will do nothing.<P>
*
* Another usage that is more efficient but bulkier:
* <BLOCKQUOTE><TT>
* if (Assert.enabled && Assert.assert(mytest(), "my test failed"));
* if (Assert.enabled && Assert.assert_it(mytest(), "my test failed"));
* </TT></BLOCKQUOTE><P>
*
* Such usage prevents not only <TT>mytest()</TT> from being executed if
* assertions are disabled but also the assert method itself, and some
* assertions are disabled but also the assert_it method itself, and some
* compilers can remove the entire statement if assertions are disabled.<P>
*
* <B>Assert</B> is intended for general condition and invariant testing;
@@ -102,7 +102,7 @@ static public void setEnabled(boolean newEnabled) {
* @exception AssertionFailureException if <I>test</I> is false
* @return true
*/
static public boolean assert (boolean test, String message) {
static public boolean assert_it (boolean test, String message) {
if (enabled && !test) {
throw new AssertionFailureException (message);
}
@@ -117,7 +117,7 @@ static public boolean assert (boolean test, String message) {
* @exception AssertionFailureException if <I>test</I> is false
* @return true
*/
static public boolean assert (boolean test) {
static public boolean assert_it (boolean test) {
if (enabled && !test) {
throw new AssertionFailureException ();
}