I'd create a function called isEmpty, or call of a static method on a class.
VenueGlobal( (isEmpty( sousVenues) ) )
Mark
vdelbart wrote:
Hi,
I have an object 'VenueGlobal' with a property 'sousVenues' who is a List
of
SousVenue. I try to test the emptyness of this list in on sentence but i
don't know why it doesn't work :
I try this :
VenueGlobal( sousVenues == null || sousVenues.empty )
but I have this error :
org.drools.rule.InvalidRulePackage: [11,53]: unknown:11:53 Unexpected token
')'
at org.drools.rule.Package.checkValidity(Package.java:424)
I try this :
VenueGlobal( sousVenues == null || sousVenues.size == 0 )
but I have this error :
Caused by: org.mvel.PropertyAccessException: unable to resolve property:
size
at
org.mvel.optimizers.impl.refl.ReflectiveAccessorOptimizer.getBeanProperty(ReflectiveAccessorOptimizer.java:382)
I don't know what the solution ?
regards,
V.