Thanks for your reply Earnie. In the following example, don't want to
hardcode Person Name value like "John" in the DRL file. I want to refer it
from some other sources(If i refer it from java class file, name value is
getting changed quiet often, have to recompile the java source and deploy).
My main requirement is, if the name value is getting changed, don't want to
redeploy/restart the application. i would like to do the changes in the drl
file only without hard coding.
rule "Test Rule"
when
$person : Person( name == "John")
then
$person.setActivation(true)
end
Karthikeyan
Please explain, how i can refer global object in LHS?
Earnie D wrote:
How about adding them as Globals and referencing them that way? You should
be able to put them in a map as well in a Global and reference them.
Earnie!
________________________________
From: karthizap <karthizap(a)gmail.com>
To: rules-users(a)lists.jboss.org
Sent: Monday, June 1, 2009 7:14:56 AM
Subject: re[rules-users] move hardcoded values in DRL or have constants
inside drl
Is there is anyway i can remove hardcoded values in the DRL file? Can I
have the constants file(like data dictionary) inside drl/functions. I
don't want to refer java constants class directly in drl file and would
like to declare and refer those constants inside drl file.
________________________________
View this message in context: remove hardcoded values in DRL or have
constants inside drl
Sent from the drools - user mailing list archive at
Nabble.com.
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users
--
View this message in context:
http://www.nabble.com/remove-hardcoded-values-in-DRL-or-have-constants-in...
Sent from the drools - user mailing list archive at
Nabble.com.