站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss RULES 4.0.0.11754MR2 API 英文版文档

SuggestionCompletionLoader (Drools 4.0.0.11754MR2 API) - JBoss RULES 4.0.0.11754MR2 API 英文版文档


org.drools.brms.server.rules
Class SuggestionCompletionLoader

java.lang.Object
  extended by org.drools.brms.server.rules.SuggestionCompletionLoader
Direct Known Subclasses:
BRMSSuggestionCompletionLoader

public class SuggestionCompletionLoader
extends Object

This utility class loads suggestion completion stuff for the package configuration, introspecting from models, templates etc. This also includes DSL stuff, basically, everything you need to get started with a package. It also validates the package configuration, and can provide errors. This does NOT validate assets in the package, other then to load up DSLs, models etc as needed. FYI: the tests for this are in the BRMS module, in context of a full BRMS.

Author:
Michael Neale

Field Summary
protected  List errors
           
 
Constructor Summary
SuggestionCompletionLoader()
          This uses the current classes classloader as a base, and jars can be added.
SuggestionCompletionLoader(ClassLoader classLoader)
          This allows a pre existing classloader to be used (and preferred) for resolving types.
 
Method Summary
 List getErrors()
          Returns a list of String errors.
 SuggestionCompletionEngine getSuggestionEngine(String header, List jars, List dsls)
          This will validate, and generate a new engine, ready to go.
 boolean hasErrors()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

errors

protected List errors
Constructor Detail

SuggestionCompletionLoader

public SuggestionCompletionLoader()
This uses the current classes classloader as a base, and jars can be added.


SuggestionCompletionLoader

public SuggestionCompletionLoader(ClassLoader classLoader)
This allows a pre existing classloader to be used (and preferred) for resolving types.

Method Detail

getSuggestionEngine

public SuggestionCompletionEngine getSuggestionEngine(String header,
                                                      List jars,
                                                      List dsls)
This will validate, and generate a new engine, ready to go. If there are errors, you can get them by doing getErrors();

Parameters:
header - The package configuration file content.
jars - a list of jars to look inside (pass in empty array if not needed) this is a list of JarInputStream
dsls - any dsl files. This is a list of DSLMappingFile.
Returns:
A SuggestionCompletionEngine ready to be used in anger.

hasErrors

public boolean hasErrors()
Returns:
true if there were errors when processing the package.

getErrors

public List getErrors()
Returns a list of String errors.



Copyright © 2001-2007 JBoss Inc.. All Rights Reserved.