[rules-users] Matching on instanceof without eval?

Barry Kaplan groups1 at memelet.com
Mon May 26 09:05:01 EDT 2008



Edson Tirelli-3 wrote:
> 
>    Question: what is the actual type of your "option" field? I mean, what
> class does getOption() returns? Object?
> 

There is no getOption, but rather getInstrument, where Instrument is the
base class (or interface). Position contains an Instrument, of which there
are subclasses like EquityInstrument, CashInstrument, OptionInstrument,
FixedIncomeInstrument, etc. As you suspected, there are not many subtypes
(say 20). 

-barry
-- 
View this message in context: http://www.nabble.com/Matching-on-instanceof-without-eval--tp17425953p17471591.html
Sent from the drools - user mailing list archive at Nabble.com.




More information about the rules-users mailing list