[Mathlib-commitlog] SF.net SVN: mathlib:[784] JMathLib/trunk/src/jmathlib/core/interpreter
Status: Beta
Brought to you by:
st_mueller
|
From: <st_...@us...> - 2009-01-26 19:52:04
|
Revision: 784
http://mathlib.svn.sourceforge.net/mathlib/?rev=784&view=rev
Author: st_mueller
Date: 2009-01-26 19:52:01 +0000 (Mon, 26 Jan 2009)
Log Message:
-----------
renamed MathLibException into JMathLibException
Modified Paths:
--------------
JMathLib/trunk/src/jmathlib/core/interpreter/Errors.java
JMathLib/trunk/src/jmathlib/core/interpreter/Interpreter.java
JMathLib/trunk/src/jmathlib/core/interpreter/LexicalAnalyser.java
Added Paths:
-----------
JMathLib/trunk/src/jmathlib/core/interpreter/JMathLibException.java
Modified: JMathLib/trunk/src/jmathlib/core/interpreter/Errors.java
===================================================================
--- JMathLib/trunk/src/jmathlib/core/interpreter/Errors.java 2009-01-26 19:49:18 UTC (rev 783)
+++ JMathLib/trunk/src/jmathlib/core/interpreter/Errors.java 2009-01-26 19:52:01 UTC (rev 784)
@@ -26,7 +26,7 @@
public static void throwMathLibException(int errorCode)
{
String text = getErrorText(errorCode);
- throw (new MathLibException(text));
+ throw (new JMathLibException(text));
}
@@ -36,7 +36,7 @@
@param errorCode = the error message*/
public static void throwMathLibException(String errorMessage)
{
- throw (new MathLibException("ERROR: "+errorMessage));
+ throw (new JMathLibException("ERROR: "+errorMessage));
}
/**
@@ -46,7 +46,7 @@
*/
public static void throwParserException(String errorMessage)
{
- throw (new MathLibException("PARSER: "+errorMessage));
+ throw (new JMathLibException("PARSER: "+errorMessage));
}
@@ -57,7 +57,7 @@
*/
public static void throwUsageException(String errorMessage)
{
- throw (new MathLibException("USAGE: "+errorMessage));
+ throw (new JMathLibException("USAGE: "+errorMessage));
}
/**returns the localised error string for a specific code,
@@ -68,7 +68,7 @@
public static String getErrorText(int errorCode, Object[] params)
{
String text = "";
- ResourceBundle bundle = ResourceBundle.getBundle("MathLib.ResourceBundles.ErrorBundle");
+ ResourceBundle bundle = ResourceBundle.getBundle("jmathlib.resourcebundles.ErrorBundle");
text = MessageFormat.format(bundle.getString(Integer.toString(errorCode)), params);
return text;
@@ -81,7 +81,7 @@
public static void throwMathLibException(int errorCode, Object[] params)
{
String text = getErrorText(errorCode, params);
- throw (new MathLibException(text));
+ throw (new JMathLibException(text));
}
}
Modified: JMathLib/trunk/src/jmathlib/core/interpreter/Interpreter.java
===================================================================
--- JMathLib/trunk/src/jmathlib/core/interpreter/Interpreter.java 2009-01-26 19:49:18 UTC (rev 783)
+++ JMathLib/trunk/src/jmathlib/core/interpreter/Interpreter.java 2009-01-26 19:52:01 UTC (rev 784)
@@ -132,7 +132,7 @@
//getVariables().listVariables();
}
- catch(MathLibException e)
+ catch(JMathLibException e)
{
answer = e.getMessage();
Copied: JMathLib/trunk/src/jmathlib/core/interpreter/JMathLibException.java (from rev 413, JMathLib/trunk/src/jmathlib/core/interpreter/MathLibException.java)
===================================================================
--- JMathLib/trunk/src/jmathlib/core/interpreter/JMathLibException.java (rev 0)
+++ JMathLib/trunk/src/jmathlib/core/interpreter/JMathLibException.java 2009-01-26 19:52:01 UTC (rev 784)
@@ -0,0 +1,31 @@
+/*
+ * This file is part or JMathLib
+ *
+ * Check it out at http://www.jmathlib.de
+ *
+ * Author:
+ * (c) 2002-2009
+ */
+
+
+package jmathlib.core.interpreter;
+
+/**MathLib specific exception */
+public class JMathLibException extends ArithmeticException
+{
+ /**Create a new exception object*/
+ public JMathLibException()
+ {
+
+ }
+
+ /**Set the message text
+ * @param text = the text to display
+ */
+ public JMathLibException(String text)
+ {
+ super(text);
+ }
+
+
+}
Modified: JMathLib/trunk/src/jmathlib/core/interpreter/LexicalAnalyser.java
===================================================================
--- JMathLib/trunk/src/jmathlib/core/interpreter/LexicalAnalyser.java 2009-01-26 19:49:18 UTC (rev 783)
+++ JMathLib/trunk/src/jmathlib/core/interpreter/LexicalAnalyser.java 2009-01-26 19:52:01 UTC (rev 784)
@@ -220,7 +220,7 @@
For each character it calls a series of functions until it
finds one that can handle the character
@return the next token contained within the expression string */
- private boolean scanNextToken() throws MathLibException
+ private boolean scanNextToken() throws JMathLibException
{
negative = false; // reset sign indicator
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|