[jboss-jira] [JBoss JIRA] Commented: (JBRULES-1929) In the then part (RHS) of guided rule editor, it is not possible to affect a value with variable name of the when part (LHS) and not possible to call a method in the new created instance

Michael Neale (JIRA) jira-events at lists.jboss.org
Sat Mar 7 01:10:22 EST 2009


    [ https://jira.jboss.org/jira/browse/JBRULES-1929?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12456015#action_12456015 ] 

Michael Neale commented on JBRULES-1929:
----------------------------------------

hmm.. you should be able to do this in the RHS via "formula" expression (or put the value as "=p"). 

This is not ideal - the ideal would be to know that person property of of type Person - and find any vars in scope that are of a compatible type (would be a nice enhancement).

> In the then part (RHS) of guided rule editor, it is not possible to affect a value with variable name of the when part (LHS) and not possible to call a method in the new created instance
> ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: JBRULES-1929
>                 URL: https://jira.jboss.org/jira/browse/JBRULES-1929
>             Project: JBoss Drools
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: drools-guvnor
>    Affects Versions:  5.0.0.M4
>            Reporter: Nicolas Heron
>            Assignee: Mark Proctor
>
> In drl, the rule would look like this : 
> when
>     p : Person()
>     c : Car (owner == p)
> then
>   Insurrance i = new Insurrance();
>    i.setPerson(p);
>    c.addInssurance(i);
> end 
> This cannot be done with the guided editor in Guvnor for "i.setPerson(p);"
> and also, il is not possible to call a metthod on a (LHS) defined fact outside the variables set/get methods "c.addInssurance(i);"

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list