Hello Jess users,

Quoting from the manual:

" A rule containing an 'or' conditional element with n branches is precisely equivalent to n rules, each of which has one branch as its left hand side. In fact, this is how the or conditional element is implemented: Jess internally generates one new rule for each branch."

If both branches of an OR are matched, does it lead to multiple activations? Say for example

(defrule or-example-1
    (or 
                (com_test_Test1 (OBJECT ?Test1_obj)
            (str8
                         "51"|"54"|"55"|"59"
                    ))
                (com_test_Test2 (OBJECT ?Test2_obj)
            (str12
                         "159"|"176"
                    ))
            )
        
    =>
        ( DO SOMETHING)
)

Here if we have two beans one and instance of class Test1 with str8 = 51 and the other of class Test2 with str12 = 159, 
and hence they satisfy both brances of this OR, will SOMETHING be done twice?

Thanks
Dheeraj

Reply via email to