当前页面:
在线文档首页 >
JBoss RULES 4.0.0.11754MR2 API 英文版文档
PackageBuilder.ErrorHandler (Drools 4.0.0.11754MR2 API) - JBoss RULES 4.0.0.11754MR2 API 英文版文档
org.drools.compiler
Class PackageBuilder.ErrorHandler
java.lang.Object
org.drools.compiler.PackageBuilder.ErrorHandler
- Direct Known Subclasses:
- PackageBuilder.FunctionErrorHandler, PackageBuilder.RuleErrorHandler
- Enclosing class:
- PackageBuilder
public abstract static class PackageBuilder.ErrorHandler
- extends Object
This is the super of the error handlers. Each error handler knows how to
report a compile error of its type, should it happen. This is needed, as
the compiling is done as one hit at the end, and we need to be able to
work out what rule/ast element caused the error.
An error handler it created for each class task that is queued to be
compiled. This doesn't mean an error has occurred, it just means it *may*
occur in the future and we need to be able to map it back to the AST
element that originally spawned the code to be compiled.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
message
protected String message
PackageBuilder.ErrorHandler
public PackageBuilder.ErrorHandler()
isInError
public boolean isInError()
- This needes to be checked if there is infact an error
addError
public void addError(CompilationProblem err)
getError
public abstract DroolsError getError()
- Returns:
- A DroolsError object populated as appropriate, should the
unthinkable happen and this need to be reported.
collectCompilerProblems
protected CompilationProblem[] collectCompilerProblems()
- We must use an error of JCI problem objects. If there are no
problems, null is returned. These errors are placed in the
DroolsError instances. Its not 1 to 1 with reported errors.
Copyright © 2001-2007
JBoss Inc.. All Rights Reserved.