&nbsp; <br>&nbsp;&nbsp; Yes, this should not be raising errors. <br><br>&nbsp;&nbsp; Michael,<br><br>&nbsp;&nbsp; What was the conclusion of the discussion about null handling?<br><br>&nbsp;&nbsp; Thanks,<br>&nbsp;&nbsp;&nbsp; Edson<br><br><br><div><span class="gmail_quote">2007/3/28, wasabifan &lt;
<a href="mailto:bryan.rickman@kewill.com">bryan.rickman@kewill.com</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>class MyObject {
<br>&nbsp;&nbsp;private Integer used;<br>&nbsp;&nbsp;private Integer notUsed;<br>&nbsp;&nbsp;// public setters/getters...<br>}<br><br>rule &quot;1&quot;<br>&nbsp;&nbsp;when<br>&nbsp;&nbsp;&nbsp;&nbsp;MyObject(used == 1)<br>&nbsp;&nbsp;then<br>&nbsp;&nbsp;&nbsp;&nbsp;// do something<br>end<br><br>rule &quot;2&quot;
<br>&nbsp;&nbsp;when<br>&nbsp;&nbsp;&nbsp;&nbsp;UnrelatedObject(data == 5)<br>&nbsp;&nbsp;&nbsp;&nbsp;MyObject(notUsed == 2)<br>&nbsp;&nbsp;then<br>&nbsp;&nbsp;&nbsp;&nbsp;// do something else<br>end<br><br>Basically, I am trying to create JUnit test cases to test each of the rules<br>functionality.&nbsp;&nbsp;So I would instantiate and object, set the required data to
<br>fire a rule, assert the object and fire all rules.&nbsp;&nbsp;So when setting<br>MyObject.used = 1, then asserting that fact...it appears that rule 2 would<br>complain that notUsed is null (even though I do not have an asserted fact
<br>where UnrelatedObject(data == 5).<br><br>Does this make sense?&nbsp;&nbsp;I know this is sort of pseudo code thrown together<br>quickly, but I think that explains what I was experiencing.&nbsp;&nbsp;If not, I can<br>go back to get some of the actual code, but that would be much longer.
<br><br>Thanks,<br>Bryan<br><br><br>Edson Tirelli-3 wrote:<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Can you please provide one example for us to understand better the<br>&gt; case?<br>&gt;<br><br>--<br>View this message in context: <a href="http://www.nabble.com/comparisons-on-Java-primitive-wrapper-class-types-tf3481733.html#a9721787">
http://www.nabble.com/comparisons-on-Java-primitive-wrapper-class-types-tf3481733.html#a9721787</a><br>Sent from the drools - user mailing list archive at <a href="http://Nabble.com">Nabble.com</a>.<br><br>_______________________________________________
<br>rules-users mailing list<br><a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users
</a><br></blockquote></div><br><br clear="all"><br>-- <br>&nbsp;&nbsp;Edson Tirelli<br>&nbsp;&nbsp;Software Engineer - JBoss Rules Core Developer<br>&nbsp;&nbsp;Office: +55 11 3124-6000<br>&nbsp;&nbsp;Mobile: +55 11 9218-4151<br>&nbsp;&nbsp;JBoss, a division of Red Hat @ 
<a href="http://www.jboss.com">www.jboss.com</a>