[rules-users] How can I reason over non collection based arrays?

Henry Canterburry canterburry at gmail.com
Tue Jan 29 16:15:26 EST 2008


OK...new discovery...the class case exception only happens if I apply a 
criteria to the pattern:

For example:

$filtered : MyObjectType() from $source.getMyObjectTypes() << returns MyObjectType[]

works while...

$filtered : MyObjectType( field != null ) from $source.getMyObjectTypes() << returns MyObjectType[]

Gives me a ClassCastException.

HC


H. Canterburry wrote:
> No...no one?
>
> My primary concern is to apply a filtering pattern to an array like so...
> (this array is non collections based)
>
> when
> $source : SourceObject()
> $filtered : MyObjectType( field == "criteria" ) from
> $source.getMyObjectTypes() << returns MyObjectType[]
> then
> ... do something with the filtered object
>
> I am getting a ClassCaseException in the from line.
>
> Anyone? Please?
> HC
>
>
>   




More information about the rules-users mailing list