[rules-users] RE: Need DRL authoring Help
Michael Neale
michael.neale at gmail.com
Thu Apr 5 02:47:07 EDT 2007
OK you are really bending what you would use rules for, I really wouldn't
recommend that. flattening the object model would allow you to write rules
over it, but as it stands, its just going to be a bit difficult for you.
catalogObject : CatalogObject( )
*eval*( catalogObject.getElementValue("depth") == *null* ||
catalogObject.getElementValue("depth") == "" )
On 4/5/07, John.Tal at gxs.com <John.Tal at gxs.com> wrote:
>
> Ok, Thanks for the help on the drl syntax.
>
>
>
> So this works.
>
>
>
> *rule* "UCCnet_DVE_Depth_All"
>
> *when*
>
> catalogObject : CatalogObject( )
>
> *eval*( catalogObject.getElementValue("depth") == *null* ||
> catalogObject.getElementValue("depth") == "" )
>
> *then*
>
> logWriter.logDebug("Package Depth is Blank");
>
> *end*
>
>
>
>
>
> But how do I get the drl parser to accept something like this:
>
>
>
> *rule* "UCCnet_DVE_Depth_All"
>
> *when*
>
> catalogObject : CatalogObject( )
>
> String s = catalogObject.getElementValue("depth");
>
> *eval*( s == *null* || s == "" )
>
> *then*
>
> logWriter.logDebug("Package Depth is Blank");
>
> *end*
>
>
>
> I am getting an Unexpected token 's' InvalidRulePackage
>
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20070405/91b1ed05/attachment.html
More information about the rules-users
mailing list