opale.tools
Class Assert

java.lang.Object
  |
  +--opale.tools.Assert

public class Assert
extends java.lang.Object

This class makes it possible to check assertion in the programms. It's possible to use the conditionale compilation of javac compiler with testing the boolean Assert.enabled :

if (Assert.enabled) Assert.check(i==0);

This class is compatible with the java spec 1.4 because of the keyword assert is not used.

Since:
Opale-Tools 0.15

Field Summary
static boolean enabled
          enabled = true for the debugging mode.
 
Constructor Summary
Assert()
           
 
Method Summary
static void check(boolean i)
          Verify an assertion.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

enabled

public static final boolean enabled
enabled = true for the debugging mode.
Constructor Detail

Assert

public Assert()
Method Detail

check

public static void check(boolean i)
Verify an assertion.
Parameters:
boolean, - an assert.