rules - drools working with dates -


in official documentation can't find information how write conditional statements java.util.date type fact fields in guided rules. example how compare such field current date, check if equal omitting time, or check if date before time now?

drools isn't real-time program , doesn't have innate idea of time or now. if need investigate relations of fact property w.r.t. point of time x, you'll have establish fact carrying x data, , write rules based on that.

a more or less coarse approximation of fact representing can made using timers. can implement rule modifies fact containing value representing time (e.g. java.util.date) every second, or less frequently.

blending out time of day you'll have using java or drl functions. alternatively, if days interested in, use custom class representing days, suitable day 1 defined you.


Comments

Popular posts from this blog

c++ - QTextObjectInterface with Qml TextEdit (QQuickTextEdit) -

javascript - angular ng-required radio button not toggling required off in firefox 33, OK in chrome -

xcode - Swift Playground - Files are not readable -