Thanks W,
From: laune [via Drools] [mailto:ml-node+[hidden email]]
Sent: Monday, March 03, 2014 3:34 PM
To: Gopu Shrestha
Subject: Re: [rules-users] accumulate Map()
Is there an
import java.util.Map
import java.util.HashMap
in the DRL?
-W
On 03/03/2014, Gopu Shrestha <[hidden email]> wrote:
> Sorry, Here is the complete code:
>
> rule "map accumulate"
>
> when
> $headers : Map() from accumulate(RulesHeader($headerName : name in
> ("some_ErrorInfo"), $headerValue : valueAsString not in (null, "")),
> init(Map headers = new HashMap();)
> action(headers.put($headerName, $headerValue);)
> result(headers))
> then
> log.info("Executing rule map accumulate ....");
>
> end
>
> Error:-------------------------------
>
> Unable to resolve ObjectType 'Map'
> Error while executing rules ::: Errors encountered in rules package :
> Unable to resolve ObjectType 'Map' : [Rule name='map accumulate']
>
> Error while executing rules
> java.lang.RuntimeException: Errors encountered in rules package :
> Unable to resolve ObjectType 'Map' : [Rule name='map accumulate']
>
>
>
>
>
> -----Original Message-----
> From: [hidden email]
> [mailto:[hidden email]] On Behalf Of Wolfgang Laun
> Sent: Monday, March 03, 2014 3:25 PM
> To: Rules Users List
> Subject: Re: [rules-users] accumulate Map()
>
> Guessing game time, huh?
>
>
> On 03/03/2014, Gopu Shrestha <[hidden email]> wrote:
>> This accumulate is not working.. any advice?
>>
>> $headers : Map() from accumulate(RulesHeader($headerName : name in (
>> "some_ErrorInfo"), $headerValue : valueAsString not in
>> (null, "")),
>> init(Map headers = new HashMap();)
>> action(headers.put($headerName, $headerValue);)
>> result(headers))
>>
>>
> _______________________________________________
> rules-users mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/rules-users
>
> _______________________________________________
> rules-users mailing list
> [hidden email]
> https://lists.jboss.org/mailman/listinfo/rules-users
>
_______________________________________________
rules-users mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/rules-users
If you reply to this email, your message will be added to the discussion below:
http://drools.46999.n3.nabble.com/rules-users-accumulate-Map-tp4028463p4028466.html
To start a new topic under Drools: User forum, email
[hidden email]
To unsubscribe from Drools,
click here.
NAML