Hi, I have a rule that on its RHS, it creates new objects with random content
and inserts them.
How do you check if the object already exists in drools memory?
I am thinking to use kcontext.getKnowledgeRuntime().getObjects() in the RHS
to loop for all the objects and stop inserting if an object wi
Quote from the Expert manual:
"A Working Memory may operate in two assertion modes, i.e., equality
or identity, with identity being the default."
Search for the keyword to see all references; you'll need "equality".
-W
On 05/12/2013, Sonata wrote:
> Hi, I have a rule that on its RHS, it crea
Thanks
I made a search and it seems it is controlled by a config to switch between
identity or equality. Since I can only write rules, I can't enjoy the
advantage of that.
I ended up writing a retract rule to retract the same (equal) object from
memory with higher salience. So everytime some rules