controlexception.java

来自「JAVA 数学程序库 提供常规的数值计算程序包」· Java 代码 · 共 42 行

JAVA
42
字号
package jmathlib.core.interpreter;

import jmathlib.core.tokens.OperandToken; 
import jmathlib.core.tokens.Token; 

/**MathLib specific exception */
public class ControlException extends ArithmeticException
{
    public static final int Return = 0;
    public static final int Yield = 0;

    private int type;

    private OperandToken result;

    /**Create a new exception object*/
    public ControlException()
    {
    	type = 0;
    	result = null;
    }
    
    /**Set the message text
     @param text = the text to display*/
    public ControlException(int _type, Token _result)
    {
    	super("");
    	type = _type;
    	result = ((OperandToken)_result);
    }

    public int getType()
    {
    	return type;
    }

    public OperandToken getResults()
    {
    	return result;
    }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?