我是 JBOSS DROOLS 的新手,我需要在 DROOLS 规则上的伪代码下面。让我知道任何聪明的方式 imp DROOLS 规则。
if(Prod_of_Interest == "Signature Card" || Prod_nm == "001")
seg= '5555'
else if(Prod_of_Interest == "SBI Platinum Card" || Prod_nm == "002")
seg= '6666'
else if(Prod_of_Interest ==SBI Platinum Card == "SBI Gold & More Card" || Prod_nm == "003")
seg= '7777'
else if(Prod_of_Interest ==SBI Platinum Card == "Yatra SBI Card" || Prod_nm == "004")
seg= '8888'
else if(Prod_of_Interest ==SBI Platinum Card == "SpiceJet SBI Card" || Prod_nm == "005")
seg= '9999'
else if(Prod_of_Interest ==SBI Platinum Card == "SBI Maruti Card" || Prod_nm == "006")
seg= '1111'
else if(Prod_of_Interest ==SBI Platinum Card == "TATA Card" || Prod_nm == "007")
seg= '2222'
else if(Prod_of_Interest ==SBI Platinum Card == "SBI Oriental Bank of Commerce Platinum Card" || Prod_nm == "008")
seg= '3333'
流口水规则
rule "Card1"
when
CARD( Prod_of_Interest == Signature Car || Prod_nm : 001 )
then
Response s= new Response()
s.setSeg( "5555" );
end