|
IDebug © 1997-2001 Joseph Kiniry © 2000-2001 KindSoftware © 1997-1999 Caltech All Rights Reserved |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
DebugConstants is an interface that collects the
various constants of the debugging package including debug level ranges,
standard debugging messages, statistics definitions, etc.
This interface can be implemented or the default implementation of it can be subtyped to modify the various values contained herein for specific debugging subpackages, applications, etc.
An example of such a subtype is included as
FrenchConstants.
The default categories are specified in the following table.
| Category | Level | Description |
| ASSERTION | 9 | The highest level category that exists. Assertions are predicates that must be true. If an assertion is false, a stack dump takes place and the object in question should shut down in an orderly fashion. Note that a single assertion should be made for each predicate that is in the precondition, postcondition, requires, and ensures expressions for every method. |
| FAILURE | 9 | The highest level category that exists. Sometimes a object need fail outside an assertion. This default category provides this functionality. If a failure is seen, a stack dump takes place and the object in question should shut down in an orderly fashion. |
| CRITICAL | 7 | Very important problems/errors that will eventually cause Failures or Assertions should be tagged as Critical. The user/system must be information of such problems but the object in question need not shut down immediately and can potentially recover. Typical examples of Critial errors are resource-related errors (out of memory, disk space, cpu time, etc.). |
| ERROR | 5 | This is the standard error level. An Error means "something went wrong and the user should probably be notified whether the the system can automatically recover properly or not". |
| WARNING | 3 | A warning is a message that says something has gone wrong but it's not terribly serious. Warnings are often, but not always, communicated on to the user. |
| NOTICE | 1 | A notice is simply a progress message. Notices are used to track a thread of control during debugging. |
Debug,
Context,
Assert,
DebugOutput,
Collect,
Statistic,
DefaultDebugConstants,
FrenchConstants| Field Summary | |
static java.lang.String |
ASSERTION
The highest level category that exists. |
static int |
ASSERTION_LEVEL
The highest level category that exists. |
static java.lang.String |
CRITICAL
Very important problems/errors that will eventually cause Failures or Assertions should be tagged as Critical. |
static int |
CRITICAL_LEVEL
Very important problems/errors that will eventually cause Failures or Assertions should be tagged as Critical. |
static java.lang.String |
ERROR
This is the standard error level. |
static int |
ERROR_LEVEL
This is the standard error level. |
static java.lang.String |
ERROR_STRING
An error message that can be localized or otherwise customized. |
static java.lang.String |
FAILED_ASSERTION_STRING
An assertion failure message that can be localized or otherwise customized. |
static java.lang.String |
FAILURE
The highest level category that exists. |
static int |
FAILURE_LEVEL
The highest level category that exists. |
static int |
INVALID_THREAD
Indicates that an invalid thread was passed to a thread-related method in idebug.Debug. |
static int |
LEVEL_MAX
The maximum debug level. |
static int |
LEVEL_MIN
The minimum debug level. |
static java.lang.String |
NOTICE
A notice is simply a progress message. |
static int |
NOTICE_LEVEL
A notice is simply a progress message. |
static java.lang.String |
WARNING
A warning is a message that says something has gone wrong but it's not terribly serious. |
static int |
WARNING_LEVEL
A warning is a message that says something has gone wrong but it's not terribly serious. |
| Method Summary | |
boolean |
checkLevel(int l)
Check whether a level is valid, that is, bound byte the minimum and maximum levels of this interface's implementation. |
void |
initCategories(java.util.Hashtable hashtable)
Initializes default categories of debugging facilities. |
| Field Detail |
public static final int LEVEL_MIN
The minimum debug level.
public static final int LEVEL_MAX
The maximum debug level.
public static final java.lang.String ERROR_STRING
An error message that can be localized or otherwise customized.
public static final java.lang.String FAILED_ASSERTION_STRING
An assertion failure message that can be localized or otherwise customized.
public static final int ASSERTION_LEVEL
The highest level category that exists. Assertions are predicates that must be true. If an assertion is false, a stack dump takes place and the object in question should shut down in an orderly fashion. Note that a single assertion should be made for each predicate that is in the precondition, postcondition, requires, and ensures expressions for every method.
public static final int FAILURE_LEVEL
The highest level category that exists. Sometimes a object need fail outside an assertion. This default category provides this functionality. If a failure is seen, a stack dump takes place and the object in question should shut down in an orderly fashion.
public static final int CRITICAL_LEVEL
Very important problems/errors that will eventually cause Failures or Assertions should be tagged as Critical. The user/system must be information of such problems but the object in question need not shut down immediately and can potentially recover. Typical examples of Critial errors are resource-related errors (out of memory, disk space, cpu time, etc.).
public static final int ERROR_LEVEL
This is the standard error level. An Error means "something went wrong and the user should probably be notified whether the the system can automatically recover properly or not".
public static final int WARNING_LEVEL
A warning is a message that says something has gone wrong but it's not terribly serious. Warnings are often, but not always, communicated on to the user.
public static final int NOTICE_LEVEL
A notice is simply a progress message. Notices are used to track a thread of control during debugging.
public static final java.lang.String ASSERTION
The highest level category that exists. Assertions are predicates that must be true. If an assertion is false, a stack dump takes place and the object in question should shut down in an orderly fashion. Note that a single assertion should be made for each predicate that is in the precondition, postcondition, requires, and ensures expressions for every method.
public static final java.lang.String FAILURE
The highest level category that exists. Sometimes a object need fail outside an assertion. This default category provides this functionality. If a failure is seen, a stack dump takes place and the object in question should shut down in an orderly fashion.
public static final java.lang.String CRITICAL
Very important problems/errors that will eventually cause Failures or Assertions should be tagged as Critical. The user/system must be information of such problems but the object in question need not shut down immediately and can potentially recover. Typical examples of Critial errors are resource-related errors (out of memory, disk space, cpu time, etc.).
public static final java.lang.String ERROR
This is the standard error level. An Error means "something went wrong and the user should probably be notified whether the the system can automatically recover properly or not".
public static final java.lang.String WARNING
A warning is a message that says something has gone wrong but it's not terribly serious. Warnings are often, but not always, communicated on to the user.
public static final java.lang.String NOTICE
A notice is simply a progress message. Notices are used to track a thread of control during debugging.
public static final int INVALID_THREAD
Indicates that an invalid thread was passed to a thread-related method in idebug.Debug.
| Method Detail |
public void initCategories(java.util.Hashtable hashtable)
Initializes default categories of debugging facilities.
hashtable - is the hashtable to initialize.public boolean checkLevel(int l)
Check whether a level is valid, that is, bound byte the minimum and maximum levels of this interface's implementation.
l - the level to check.
|
IDebug © 1997-2001 Joseph Kiniry © 2000-2001 KindSoftware © 1997-1999 Caltech All Rights Reserved |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||