Class Catch
java.lang.Object
org.jfuncmachine.compiler.model.SourceElement
org.jfuncmachine.compiler.model.expr.Catch
Define a catch clause for a try-catch block
-
Field Summary
FieldsModifier and TypeFieldDescriptionfinal ExpressionThe body of the catch blockfinal StringThe class of exception to catchfinal StringThe variable that the exception is stored inFields inherited from class org.jfuncmachine.compiler.model.SourceElement
filename, lineNumber -
Constructor Summary
ConstructorsConstructorDescriptionCatch(String catchClass, String catchVariable, Expression body) Create a new catch clauseCatch(String catchClass, String catchVariable, Expression body, String filename, int lineNumber) Create a new catch clause -
Method Summary
Methods inherited from class org.jfuncmachine.compiler.model.SourceElement
generateException
-
Field Details
-
catchClass
The class of exception to catch -
catchVariable
The variable that the exception is stored in -
body
The body of the catch block
-
-
Constructor Details
-
Catch
Create a new catch clause- Parameters:
catchClass- The class of exception to catchcatchVariable- The variable that the exception is stored inbody- The body of the catch block
-
Catch
public Catch(String catchClass, String catchVariable, Expression body, String filename, int lineNumber) Create a new catch clause- Parameters:
catchClass- The class of exception to catchcatchVariable- The variable that the exception is stored inbody- The body of the catch blockfilename- The source filename this expression is associated withlineNumber- The source line number this expression is associated with
-