<div dir="ltr"><div><div><div><div>If you import a class<br></div>   import a.b.c.Const<br></div>you can use its statics in the usual way, e.g., Const.ORDER_AM<br><br></div>There&#39;s also an import static, which should let you omit the class name<br>
</div>   import static a.b.c.Const.ORDER_AM<div><div><div><div class="gmail_extra">but this might only work for static methods (at least, it did, some versions ago).<br><br></div><div class="gmail_extra">-W<br></div><div class="gmail_extra">
<br><div class="gmail_quote">On 2 May 2013 21:47, Roopa <span dir="ltr">&lt;<a href="mailto:roopa.musuley@gmail.com" target="_blank">roopa.musuley@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Hi,<br>
<br>
I am a newbie to Drools. Can anyone give me some inputs on<br>
<br>
1) How to access a static variable constant from java file into drl file.<br>
say a static constant is declared in a java file VCRuleServiceConstants.java<br>
<br>
public static final double<br>
ORDER_AMOUNT_FOP_REVIEWED_ADD_TO_EXISTING_ORDER_TIER1 = 100000;<br>
<br>
How to access this variable in the drl file.<br>
Since its not an instance variable of that class, even if I insert as a<br>
&quot;fact&quot;, unable to access the variable in drl file.<br>
<br>
I can very well use the constant value directly in the drl file, but wanted<br>
to know.<br>
Please do suggest me some options available.<br>
<br>
<br>
<br>
--<br>
View this message in context: <a href="http://drools.46999.n3.nabble.com/Access-a-static-variable-from-Java-file-to-DRL-File-tp4023641p4023645.html" target="_blank">http://drools.46999.n3.nabble.com/Access-a-static-variable-from-Java-file-to-DRL-File-tp4023641p4023645.html</a><br>

Sent from the Drools: Developer (committer) mailing list mailing list archive at Nabble.com.<br>
_______________________________________________<br>
rules-dev mailing list<br>
<a href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br>
</blockquote></div><br></div></div></div></div></div>