JNodeOS v1.1.5 API

edu.utah.janos.nodeos
Class Assert

java.lang.Object
  |
  +--edu.utah.janos.nodeos.Assert

public final class Assert
extends java.lang.Object

Assert package.

XXX Currently this is public for my convenience.

Author:
Janos Ministry of Development

Constructor Summary
Assert()
           
 
Method Summary
static void assertCheck(boolean expr, java.lang.String exprStr, java.lang.String file, int line)
          Check that the boolean expression is true.
static void assertCheck(java.lang.Object ref, java.lang.String exprStr, java.lang.String file, int line)
          Check that the given object reference is non-null.
static void assertLockedCheck(java.lang.Object obj, java.lang.String exprStr, java.lang.String file, int line)
          Assert the given object is locked.
static void ensureCheck(boolean expr, java.lang.String exprStr, java.lang.String file, int line)
          Check that the boolean expression is true.
static void ensureCheck(java.lang.Object ref, java.lang.String exprStr, java.lang.String file, int line)
          Check that the given object reference is non-null.
static void requireCheck(boolean expr, java.lang.String exprStr, java.lang.String file, int line)
          Check that the boolean expression is true.
static void requireCheck(java.lang.Object ref, java.lang.String exprStr, java.lang.String file, int line)
          Check that the given object reference is non-null.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Assert

public Assert()
Method Detail

assertCheck

public static void assertCheck(boolean expr,
                               java.lang.String exprStr,
                               java.lang.String file,
                               int line)
Check that the boolean expression is true. Calls assertFailure() if not.
Parameters:
expr - the expression to check
exprStr - the string representation of the expression
file - the name of the file the assert is in
line - the line number of the file the assert is in
See Also:
#assertFailure(String,String,String,String)

requireCheck

public static void requireCheck(boolean expr,
                                java.lang.String exprStr,
                                java.lang.String file,
                                int line)
Check that the boolean expression is true. Calls assertFailure() if not.
Parameters:
expr - the expression to check
exprStr - the string representation of the expression
file - the name of the file the require is in
line - the line number of the file the require is in
See Also:
#assertFailure(String,String,String,String)

ensureCheck

public static void ensureCheck(boolean expr,
                               java.lang.String exprStr,
                               java.lang.String file,
                               int line)
Check that the boolean expression is true. Calls assertFailure() if not.
Parameters:
expr - the expression to check
exprStr - the string representation of the expression
file - the name of the file the ensure is in
line - the line number of the file the ensure is in
See Also:
#assertFailure(String,String,String,String)

assertCheck

public static void assertCheck(java.lang.Object ref,
                               java.lang.String exprStr,
                               java.lang.String file,
                               int line)
Check that the given object reference is non-null. Calls assertFailure() if the reference is null.
Parameters:
expr - the expression to check
exprStr - the string representation of the expression
file - the name of the file the assert is in
line - the line number of the file the assert is in
See Also:
#assertFailure(String,String,String,String)

requireCheck

public static void requireCheck(java.lang.Object ref,
                                java.lang.String exprStr,
                                java.lang.String file,
                                int line)
Check that the given object reference is non-null. Calls assertFailure() if the reference is null.
Parameters:
expr - the expression to check
exprStr - the string representation of the expression
file - the name of the file the assert is in
line - the line number of the file the assert is in
See Also:
#assertFailure(String,String,String,String)

ensureCheck

public static void ensureCheck(java.lang.Object ref,
                               java.lang.String exprStr,
                               java.lang.String file,
                               int line)
Check that the given object reference is non-null. Calls assertFailure() if the reference is null.
Parameters:
expr - the expression to check
exprStr - the string representation of the expression
file - the name of the file the assert is in
line - the line number of the file the assert is in
See Also:
#assertFailure(String,String,String,String)

assertLockedCheck

public static void assertLockedCheck(java.lang.Object obj,
                                     java.lang.String exprStr,
                                     java.lang.String file,
                                     int line)
Assert the given object is locked.

JNodeOS v1.1.5 API

This documentation is Copyright (C) 1998-2001 The University of Utah. All Rights Reserved. See the file LICENSE for distribution terms.
Documentation, software, and mailing list archives for Janos can be found at the Janos Project: http://www.cs.utah.edu/flux/janos/