[jboss-jira] [JBoss JIRA] Commented: (JBRULES-1027) unable to use moderately complicated expression in from
Mark Proctor (JIRA)
jira-events at lists.jboss.org
Wed Aug 8 23:17:49 EDT 2007
[ http://jira.jboss.com/jira/browse/JBRULES-1027?page=comments#action_12371567 ]
Mark Proctor commented on JBRULES-1027:
---------------------------------------
I've tired this with the latest mvel and cannot reproduce the error.
> unable to use moderately complicated expression in from
> -------------------------------------------------------
>
> Key: JBRULES-1027
> URL: http://jira.jboss.com/jira/browse/JBRULES-1027
> Project: JBoss Rules
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: Drl Parser/Builder
> Affects Versions: 4.0.0.GA
> Reporter: Michael Neale
> Assigned To: Edson Tirelli
> Priority: Critical
> Fix For: 4.0.1
>
>
> Try the following fairly simple example, and an error will ensue:
> package sample;
> import Query;
> import Results;
> import Storage;
> rule "Verify_1"
> when
> content : Storage()
> results : Results( ) from content.search(new Query("test","field"))
> then
> System.out.println( results );
> end
> ============================================================================
> /**
> *
> */
> public class Query {
> public Query(String pattern, String column) {
> }
> }
> ============================================================================
> /**
> *
> */
> public class Results {
> public int getResultsCount() {
> return 1;
> }
> }
> ============================================================================
> /**
> *
> */
> public class Storage {
> public Results search(Query query) {
> return new Results();
> }
> }
> ============================================================================
> public class HelloWorldExample {
> public static final void main(final String[] args) throws Exception {
> BasicConfigurator.configure();
> Logger.getRootLogger().setLevel(Level.DEBUG);
> DrlParser parser = new DrlParser();
> final Reader source = new FileReader("sample.drl");
> PackageDescr descr = parser.parse(source);
> source.close();
> PackageBuilder builder = new PackageBuilder();
> builder.addPackage(descr);
> Package pkg = builder.getPackage();
> pkg.checkValidity();
> }
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list