[rules-users] getting object from hashMap in when clause and using it across the rule

Avin abhijeet.b.patil at jpmorgan.com
Mon Jan 6 05:14:12 EST 2014


Hi,
I have an list of objects (objectList) and an hashmap (referenceMap) with
similiar kind of objects. I have to check which objects in list matches with
hashMap.
i can iterate list and check it with hashMap but i am not able to get value
from from the hashmap which itself is an custom object and i need to check
its value 

below code i am using to iterate list and check it from hashMap
when 
 TempStorage($object : concentrationDataTable )
  TempStorage($mapObject : concPercentRefObjects) 
  $dataObject : ConcentrationDataTable($keyObject : concPercentRefkey)  from
$object
 eval( $mapObject.get($keyObject) != null)

I want to add variable to get this value *$mapObject.get($keyObject)* and
also check if its property getMax returns me other than 10



--
View this message in context: http://drools.46999.n3.nabble.com/getting-object-from-hashMap-in-when-clause-and-using-it-across-the-rule-tp4027524.html
Sent from the Drools: User forum mailing list archive at Nabble.com.


More information about the rules-users mailing list