[Webfunds-commits] java/webfunds/util ExceptionModel.java Panic.java
Ian Grigg
iang@cypherpunks.ai
Tue, 20 Mar 2001 19:18:15 -0400 (AST)
iang 01/03/20 19:18:15
Modified: webfunds/util Panic.java
Added: webfunds/util ExceptionModel.java
Log:
copied Panic in to new home,
added ExceptionModel as base class for all Exception groups, which
adds error number field.
Revision Changes Path
1.2 +3 -3 java/webfunds/util/Panic.java
Index: Panic.java
===================================================================
RCS file: /home/webfunds/cvsroot/java/webfunds/util/Panic.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- Panic.java 2000/06/04 18:29:48 1.1
+++ Panic.java 2001/03/20 23:18:14 1.2
@@ -1,9 +1,9 @@
-/* $Id: Panic.java,v 1.1 2000/06/04 18:29:48 gelderen Exp $
+/* $Id: Panic.java,v 1.2 2001/03/20 23:18:14 iang Exp $
*
* Copyright (c) 2000 Systemics Inc. on behalf of
* The WebFunds Development Team. All rights reserved.
*/
-package webfunds.utils;
+package webfunds.util;
/**
@@ -16,7 +16,7 @@
* XXX: We may want to extend Throwable instead of Error but Jikes doesn't
* really grok that.
*
- * @version $Revision: 1.1 $
+ * @version $Revision: 1.2 $
* @author Jeroen C. van Gelderen (gelderen@webfunds.org)
*/
public final class Panic extends Error
1.1 java/webfunds/util/ExceptionModel.java
Index: ExceptionModel.java
===================================================================
/*
* $Id: ExceptionModel.java,v 1.1 2001/03/20 23:18:14 iang Exp $
*
* Copyright (c) Systemics Ltd 1995-1999 on behalf of
* the WebFunds Development Team. All Rights Reserved.
*/
package webfunds.util;
/**
* This exception base class can be inherited by all Exception Groups
* in order to add a number to the basic Exception model.
*/
public class ExceptionModel
extends Exception
{
protected int number;
public int getNumber() { return number; }
public String toString() { return "(" + number + ") " + super.toString(); }
/**
* Internal errors detected.
*/
public static final int UNKNOWN = -1;
/**
* @param num is an error code, undefined here,
* extending classes to define
*/
public ExceptionModel(int num, String msg)
{
super(msg);
number = num;
}
}