bot
Class Assert

java.lang.Object
  extended bybot.Assert

public final class Assert
extends Object

Assert is a library of assertion routines. Asserts are used in code so you can be sure something is true before proceeding. If it is not true, the assert kills the program.


Constructor Summary
Assert()
           
 
Method Summary
static void check(boolean b)
          If b is not true, die.
static void check(boolean b, String msg)
          If b is not true, die.
static void error()
          Just kill the program.
static void error(String msg)
          Just kill the program.
static void note(boolean b, String msg)
          If b is not true, print out a message.
static void note(String msg)
          Print a message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Assert

public Assert()
Method Detail

error

public static void error()
Just kill the program.


error

public static void error(String msg)
Just kill the program.

Parameters:
msg - What to say as you go down.

check

public static void check(boolean b)
If b is not true, die.

Parameters:
b - It better be true.

check

public static void check(boolean b,
                         String msg)
If b is not true, die.

Parameters:
b - It better be true.
msg - What to say if you go down.

note

public static void note(boolean b,
                        String msg)
If b is not true, print out a message.

Parameters:
b - It should be true.
msg - What to say if b is not true.

note

public static void note(String msg)
Print a message.

Parameters:
msg - What to say.