On a rule's RHS:

    kcontext.getKnowledgeRuntime().getSessionClock()

org.drools.runtime.KnowledgeContext kcontext is automagically available. See javadoc for KnowledgeRuntime.

-W



On 9 May 2011 06:53, kkelleyjr <karl.kelley.jr@gmail.com> wrote:
t
Wolfgang Laun-2 wrote:
>
> The session clock is available from the StatefulKnowledgeSession:
>
>    SessionClock clock = kSession.getSessionClock();
>    long ctInMillis = clock.getCurrentTime();
>
>

I have seen this in the documentation... However, my issue is: how do I get
ref to kSession when the session is created through a spring
configuration... Or are you saying there is always a reference to kSession
within the rules file? if so, how is the ref to kSession accessed?

 Thanks for your responses,

--
View this message in context: http://drools.46999.n3.nabble.com/rules-users-Firing-the-rule-at-the-basis-of-time-tp2889494p2917528.html
Sent from the Drools: User forum mailing list archive at Nabble.com.
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users