<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2800.1586" name=GENERATOR></HEAD>
<BODY>
<DIV><FONT size=2>
<DIV><FONT face=Arial size=2><SPAN 
class=479580213-22022007>Hi,</SPAN></FONT></DIV>
<DIV><FONT size=2><FONT face=Arial size=2><SPAN 
class=479580213-22022007></SPAN></FONT></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=479580213-22022007>I am getting null 
pointer exception when i retract objects from working memory. please help me in 
resolving this problem....</SPAN></FONT></DIV>
<DIV><FONT size=2><FONT face=Arial size=2><SPAN 
class=479580213-22022007></SPAN></FONT></FONT>&nbsp;</DIV>
<DIV><FONT size=2><FONT face=Arial size=2><SPAN 
class=479580213-22022007></SPAN></FONT></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><SPAN class=479580213-22022007>my rule goes like 
this...</SPAN></FONT></DIV>
<DIV><FONT size=2><FONT face=Arial size=2><SPAN 
class=479580213-22022007></SPAN></FONT></FONT>&nbsp;</DIV>
<DIV><FONT size=2><FONT face=Arial size=2><SPAN 
class=479580213-22022007></SPAN></FONT></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial></FONT><FONT size=+0><SPAN class=479580213-22022007><FONT 
color=#960000>&nbsp;</DIV>
<DIV align=left></FONT><FONT color=#000000><FONT face=Arial><FONT 
size=2>package</FONT><FONT size=2> com.moto.nms</FONT></FONT></FONT></DIV>
<DIV align=left><FONT size=2><FONT face=Arial 
size=2></FONT></FONT>&nbsp;</DIV><FONT color=#960000>
<DIV align=left></FONT><FONT color=#000000><FONT face=Arial><FONT 
size=2>import</FONT><FONT size=2> 
com.moto.nms.Event;</FONT></FONT></FONT></DIV><FONT color=#960000>
<DIV align=left></FONT><FONT color=#000000><FONT face=Arial><FONT 
size=2>import</FONT><FONT size=2> 
com.adventnet.nms.topodb.ManagedObject;</FONT></FONT></FONT></DIV><FONT 
color=#960000>
<DIV align=left></FONT><FONT color=#000000><FONT face=Arial><FONT 
size=2>import</FONT><FONT size=2> 
com.motorola.nmatg.nms.topology.ManagedEntity;</FONT></FONT></FONT></DIV>
<DIV align=left><FONT size=2><FONT face=Arial 
size=2></FONT></FONT>&nbsp;</DIV><FONT color=#960000>
<DIV></FONT><FONT color=#000000><FONT face=Arial><FONT size=2>global</FONT><FONT 
size=2> com.moto.nms.Consecutive con;<SPAN 
class=479580213-22022007>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;// Consecutive is 
an simple class file which has two simple methods, getValue() and 
setValue().</SPAN></FONT></FONT></FONT></DIV>
<DIV><FONT size=2><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial></FONT></FONT></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial></FONT><FONT size=+0><SPAN class=479580213-22022007><FONT 
color=#960000>&nbsp;</DIV>
<DIV align=left></FONT><FONT face=Arial><FONT color=#000000><FONT 
size=2>rule</FONT><FONT size=2> </FONT><FONT 
size=2>"duplicate"</FONT></FONT><FONT color=#008000></DIV></FONT></FONT>
<DIV align=left><B><FONT color=#960000><FONT face=Arial 
size=2>salience</FONT></B></FONT><FONT face=Arial size=2> 29</FONT></DIV>
<DIV align=left><B><FONT color=#960000><FONT face=Arial 
size=2>when</FONT></DIV></B></FONT>
<DIV align=left><FONT face=Arial size=2>e1 : Event( firsttime1 : time , 
severity1 : severity == 1 )</FONT></DIV>
<DIV align=left><FONT face=Arial size=2>e2 : Event( firsttime2 : time &gt; 
firsttime1 , severity == severity1 )</FONT></DIV>
<DIV align=left><B><FONT color=#960000><FONT face=Arial 
size=2>not</FONT></B></FONT><FONT face=Arial size=2> Event( severity == -1 , 
time &gt; firsttime1 , time &lt; firsttime2)</FONT></DIV>
<DIV align=left><B><FONT color=#960000><FONT face=Arial 
size=2>then</FONT></DIV></B></FONT>
<DIV align=left><FONT face=Arial size=2>System.out.println(<FONT 
color=#008000>"matched the fact"</FONT>);</FONT></DIV>
<DIV align=left><FONT face=Arial size=2>e1.setCompressionStatus(<FONT 
color=#008000>"compress_"</FONT>+con.getValue());</FONT></DIV>
<DIV align=left><FONT face=Arial size=2>e2.setCompressionStatus(<FONT 
color=#008000>"compress_"</FONT>+con.getValue());</FONT></DIV><FONT 
color=#960000>
<DIV align=left><FONT face=Arial color=#000000 size=2>end</FONT></DIV></FONT>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV align=left><FONT size=2><FONT face=Arial 
size=2></FONT></FONT>&nbsp;</DIV><FONT color=#960000>
<DIV align=left></FONT><FONT face=Arial><FONT color=#000000><FONT 
size=2>rule</FONT><FONT size=2> </FONT><FONT 
size=2>"duplicate_x"</FONT></FONT><FONT color=#008000></DIV></FONT></FONT>
<DIV align=left><B><FONT color=#960000><FONT face=Arial 
size=2>salience</FONT></B></FONT><FONT face=Arial size=2> 29</FONT></DIV>
<DIV align=left><B><FONT color=#960000><FONT face=Arial 
size=2>when</FONT></DIV></B></FONT>
<DIV align=left><FONT face=Arial size=2>e1 : Event(firsttime1 : time , severity 
== 1 )</FONT></DIV>
<DIV align=left><FONT face=Arial size=2>e2 : Event(firsttime2 : time &gt; 
firsttime1 , severity == 1)</FONT></DIV>
<DIV align=left><B><FONT color=#960000><FONT face=Arial 
size=2>exists</FONT></B></FONT><FONT face=Arial size=2> Event(&nbsp;<SPAN 
class=479580213-22022007>severity == -1, </SPAN>time &gt; firsttime1 , time &lt; 
firsttime2)</FONT></DIV>
<DIV align=left><B><FONT color=#960000><FONT face=Arial 
size=2>then</FONT></DIV></B></FONT>
<DIV align=left><FONT face=Arial size=2>System.out.println(<FONT 
color=#008000>"matched 2nd fact"</FONT>);</FONT></DIV>
<DIV align=left><FONT face=Arial size=2>con.setValue(con.getValue() 
+1);</FONT></DIV><FONT color=#960000>
<DIV align=left><FONT face=Arial color=#000000 
size=2><STRONG>end</STRONG></FONT></DIV>
<DIV align=left><FONT size=2><FONT color=#000000><FONT face=Arial 
size=2></FONT></FONT></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial color=#000000 size=2><SPAN 
class=479580213-22022007>exception is like this...</SPAN></FONT></DIV><FONT 
size=2>
<DIV align=left><FONT face=Arial color=#000000>Caught </FONT></FONT><FONT 
color=#000080 size=2><FONT face=Arial 
color=#000000><U>Exceptionjava.lang.NullPointerException</U></FONT></DIV>
<DIV align=left><FONT face=Arial 
color=#000000>java.lang.NullPointerException</FONT></DIV></FONT><FONT 
color=#ff0000 size=2>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.beta.DefaultRightMemory.remove(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.BetaMemory.remove(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.NotNode.retractObject(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.ObjectSource.propagateRetractObject(Unknown 
Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.RightInputAdapterNode.retractTuple(Unknown 
Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.TupleSource.propagateRetractTuple(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.NotNode.retractTuple(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.TupleSource.propagateRetractTuple(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.JoinNode.retractTuple(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.LeftInputAdapterNode.retractObject(Unknown 
Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.ObjectSource.propagateRetractObject(Unknown 
Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.AlphaNode.retractObject(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.ObjectSource.propagateRetractObject(Unknown 
Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.ObjectTypeNode.retractObject(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.Rete.retractObject(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.ReteooRuleBase.retractObject(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.reteoo.ReteooWorkingMemory.doRetract(Unknown Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.common.AbstractWorkingMemory.retractObject(Unknown 
Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
org.drools.common.AbstractWorkingMemory.retractObject(Unknown 
Source)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
com.moto.nms.TestEvents3.retractAll(</FONT></FONT><U><FONT size=2><FONT 
face=Arial color=#000000>TestEvents3.java:219</FONT></U></FONT><FONT 
color=#ff0000 size=2><FONT face=Arial color=#000000>)</FONT></DIV>
<DIV align=left><FONT face=Arial color=#000000>at 
com.moto.nms.TestEvents3.readRule(</FONT></FONT><U><FONT size=2><FONT face=Arial 
color=#000000>TestEvents3.java:158</FONT></U></FONT><FONT color=#ff0000 
size=2><FONT face=Arial color=#000000>)</FONT></DIV>
<DIV><FONT face=Arial color=#000000>at 
com.moto.nms.TestEvents3.main(</FONT></FONT><U><FONT size=2><FONT face=Arial 
color=#000000>TestEvents3.java:242</FONT></U></FONT><FONT color=#ff0000 
size=2><FONT face=Arial color=#000000>)</FONT></DIV></FONT></FONT>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV align=left><SPAN class=479580213-22022007><FONT face=Arial 
size=2>TestEvents3.java class is like this....</FONT></SPAN></DIV>
<DIV align=left><FONT size=2><FONT face=Arial 
size=2></FONT></FONT>&nbsp;</DIV><FONT color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>package</FONT></FONT><FONT 
size=2><FONT face=Arial> com.moto.nms;</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV></FONT><FONT color=#3f7f5f 
size=2>
<DIV align=left><FONT face=Arial color=#000000>//related to 
IO..</FONT></DIV></FONT><FONT color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> java.io.InputStreamReader;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> java.io.Reader;</FONT></DIV></FONT><FONT color=#7f0055 
size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> java.io.InputStream;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> java.util.List;</FONT></DIV></FONT><FONT color=#7f0055 
size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> java.util.Iterator;</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV></FONT><FONT color=#3f7f5f 
size=2>
<DIV align=left><FONT face=Arial color=#000000>//related to 
Drools..</FONT></DIV></FONT><FONT color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> org.drools.RuleBase;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> org.drools.RuleBaseFactory;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> 
org.drools.compiler.PackageBuilder;</FONT></DIV></FONT><FONT color=#7f0055 
size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> org.drools.rule.Package;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> org.drools.WorkingMemory;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> org.drools.FactHandle;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> org.drools.FactException;</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV></FONT><FONT color=#7f0055 
size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> com.moto.nms.Event;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> com.moto.nms.NMSEvent;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> com.moto.nms.TopoInterface1;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> com.moto.nms.GenerateEvents;</FONT></DIV></FONT><FONT 
color=#7f0055 size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> 
com.adventnet.nms.topodb.ManagedObject;</FONT></DIV></FONT><FONT color=#7f0055 
size=2>
<DIV align=left><FONT face=Arial color=#000000>import</FONT></FONT><FONT 
size=2><FONT face=Arial> com.moto.nms.Consecutive;</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV></FONT><FONT color=#7f0055 
size=2>
<DIV align=left><FONT face=Arial color=#000000>public</FONT></FONT><FONT 
face=Arial><FONT size=2> </FONT><FONT size=2>class</FONT></FONT><FONT 
size=2><FONT face=Arial> TestEvents3 {</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>private</FONT></B></FONT><FONT face=Arial><FONT size=2> Reader 
</FONT><FONT color=#0000c0 size=2>reader</FONT></FONT><FONT size=2><FONT 
face=Arial>;</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>private</FONT></B></FONT><FONT face=Arial><FONT size=2> RuleBase 
</FONT><FONT color=#0000c0 size=2>rulebase</FONT></FONT><FONT size=2><FONT 
face=Arial>;</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>private</FONT></B></FONT><FONT face=Arial><FONT size=2> WorkingMemory 
</FONT><FONT color=#0000c0 size=2>wm</FONT></FONT><FONT size=2><FONT 
face=Arial>;</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>private</FONT></B></FONT><FONT face=Arial><FONT size=2> List 
</FONT><FONT color=#0000c0 size=2>factHandles</FONT></FONT><FONT size=2><FONT 
face=Arial>;</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>public</FONT></B></FONT><FONT size=2><FONT face=Arial> 
TestEvents3(){</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>public</FONT></B></FONT><FONT face=Arial><FONT size=2> 
</FONT><B><FONT color=#7f0055 size=2>void</B></FONT></FONT><FONT 
face=Arial><FONT size=2> readRule(String readername) </FONT><B><FONT 
color=#7f0055 size=2>throws</B></FONT></FONT><FONT size=2><FONT face=Arial> 
Exception{</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>InputStream str = </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>null</FONT></B></FONT><FONT size=2><FONT 
face=Arial>;</FONT></DIV>
<DIV align=left><FONT face=Arial>str = TestEvents.</FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>class</FONT></B></FONT><FONT size=2><FONT 
face=Arial>.getResourceAsStream(readername);</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>if</FONT></B></FONT><FONT face=Arial><FONT size=2>(str == 
</FONT><B><FONT color=#7f0055 size=2>null</B></FONT></FONT><FONT size=2><FONT 
face=Arial>)</FONT></DIV>
<DIV align=left><FONT face=Arial>{</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"unable to read rule 
file"</FONT></FONT><FONT size=2><FONT face=Arial>);</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>return</FONT></B></FONT><FONT size=2><FONT face=Arial>;</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial><FONT color=#0000c0 
size=2>reader</FONT><FONT size=2> = </FONT><B><FONT color=#7f0055 
size=2>new</B></FONT></FONT><FONT face=Arial><FONT size=2> 
InputStreamReader(str); </FONT><FONT color=#3f7f5f size=2>//read in the 
source</DIV></FONT></FONT><FONT size=2>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>PackageBuilder builder = </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> PackageBuilder(); </FONT><FONT color=#3f7f5f 
size=2>//building up the rule package</DIV></FONT></FONT><FONT size=2>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>builder.addPackageFromDrl(</FONT></FONT><FONT 
face=Arial color=#0000c0 size=2>reader</FONT><FONT size=2><FONT 
face=Arial>);</FONT></DIV>
<DIV align=left><FONT face=Arial>Package pkg = builder.getPackage(); 
</FONT></FONT><FONT color=#3f7f5f size=2><FONT face=Arial>//get the compiled 
package</FONT></DIV></FONT><FONT size=2>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 
size=2>rulebase</FONT><FONT size=2><FONT face=Arial> = 
RuleBaseFactory.<I>newRuleBase</I>();</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial><FONT color=#0000c0 
size=2>rulebase</FONT><FONT size=2>.addPackage( pkg ); </FONT><FONT 
color=#3f7f5f size=2>//adding the package to the rule 
base</DIV></FONT></FONT><FONT size=2>
<DIV align=left><FONT face=Arial>Consecutive con = </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT size=2><FONT 
face=Arial> Consecutive();</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial><FONT color=#0000c0 
size=2>wm</FONT><FONT size=2> = </FONT><FONT color=#0000c0 
size=2>rulebase</FONT></FONT><FONT size=2><FONT 
face=Arial>.newWorkingMemory();</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial><FONT color=#0000c0 
size=2>wm</FONT><FONT size=2>.setGlobal(</FONT><FONT color=#2a00ff 
size=2>"con"</FONT></FONT><FONT size=2><FONT face=Arial>, con);</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"\n\n"</FONT></FONT><FONT 
size=2><FONT face=Arial>+System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>Event ev1 = </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(183, 1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left></FONT><FONT color=#3f7f5f size=2><FONT 
face=Arial>//Thread.sleep(450);</FONT></DIV></FONT><FONT size=2>
<DIV align=left><FONT face=Arial>Event ev9 = </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(192, 1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left></FONT><FONT color=#3f7f5f size=2><FONT 
face=Arial>//Thread.sleep(400);</FONT></DIV></FONT><FONT size=2>
<DIV align=left><FONT face=Arial>Event ev10 = </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(307, 1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial>Thread.<I>sleep</I>(500);</FONT></DIV>
<DIV align=left><FONT face=Arial>Event ev11= </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(306, 1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial>Thread.<I>sleep</I>(200);</FONT></DIV>
<DIV align=left><FONT face=Arial>Event ev12= </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(305, 1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial>Thread.<I>sleep</I>(250);</FONT></DIV>
<DIV align=left><FONT face=Arial>Event ev13= </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(304, -1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial>Thread.<I>sleep</I>(600);</FONT></DIV>
<DIV align=left><FONT face=Arial>Event ev14= </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(302, 1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial>Thread.<I>sleep</I>(200);</FONT></DIV>
<DIV align=left><FONT face=Arial>Event ev15= </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(301, 1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial>Thread.<I>sleep</I>(200);</FONT></DIV>
<DIV align=left><FONT face=Arial>Event ev16= </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT 
face=Arial><FONT size=2> Event(308, 1, </FONT><FONT color=#2a00ff 
size=2>"port02"</FONT><FONT size=2>, </FONT><FONT color=#2a00ff 
size=2>"LOS"</FONT></FONT><FONT size=2><FONT face=Arial>, 
System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev1);</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev9);</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev10);</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev11);</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev12);</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev13);</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev14);</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev15);</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.assertObject(ev16);</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"\n\n"</FONT></FONT><FONT 
size=2><FONT face=Arial>+System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"\n\nFiring 
rules...\n"</FONT></FONT><FONT size=2><FONT face=Arial>);</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.fireAllRules();</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><FONT face=Arial><FONT color=#0000c0 
size=2>factHandles</FONT><FONT size=2> = </FONT><FONT color=#0000c0 
size=2>wm</FONT></FONT><FONT size=2><FONT face=Arial>.getObjects();</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"\n\nAll the Objects in 
WOrking Memory are as Follows...\n"</FONT></FONT><FONT size=2><FONT 
face=Arial>);</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>for</FONT></B></FONT><FONT face=Arial><FONT size=2>(</FONT><B><FONT 
color=#7f0055 size=2>int</B></FONT></FONT><FONT face=Arial><FONT size=2> i=0; 
i&lt;</FONT><FONT color=#0000c0 size=2>factHandles</FONT></FONT><FONT 
size=2><FONT face=Arial>.size(); i++)</FONT></DIV>
<DIV align=left><FONT face=Arial>{</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#0000c0 size=2>factHandles</FONT></FONT><FONT 
size=2><FONT face=Arial>.get(i));</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"The CompressionStatus of the 
events are..."</FONT></FONT><FONT size=2><FONT face=Arial>);</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev1.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev9.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev10.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev11.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev12.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev13.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev14.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev15.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev16.getCompressionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"The DeletionStatus of the 
events are..."</FONT></FONT><FONT size=2><FONT face=Arial>);</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev1.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev9.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev10.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev11.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev12.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev13.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev14.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev15.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(ev16.getDeletionStatus());</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>Thread.<I>sleep</I>(1000);</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"Starting 
retracting...."</FONT></FONT><FONT size=2><FONT face=Arial>);</FONT></DIV>
<DIV align=left><FONT face=Arial>Thread.<I>sleep</I>(1000);</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>retractAll();</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT size=2><FONT 
face=Arial>.println(System.<I>currentTimeMillis</I>());</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>public</FONT></B></FONT><FONT face=Arial><FONT size=2> 
</FONT><B><FONT color=#7f0055 size=2>void</B></FONT></FONT><FONT size=2><FONT 
face=Arial> retractAll()</FONT></DIV>
<DIV align=left><FONT face=Arial>{</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial><FONT color=#0000c0 
size=2>factHandles</FONT><FONT size=2> = </FONT><FONT color=#0000c0 
size=2>wm</FONT></FONT><FONT size=2><FONT 
face=Arial>.getFactHandles();</FONT></DIV>
<DIV align=left><FONT face=Arial>Iterator itr = </FONT></FONT><FONT face=Arial 
color=#0000c0 size=2>factHandles</FONT><FONT size=2><FONT 
face=Arial>.iterator();</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>if</FONT></B></FONT><FONT face=Arial><FONT size=2>(</FONT><FONT 
color=#0000c0 size=2>factHandles</FONT><FONT size=2> == </FONT><B><FONT 
color=#7f0055 size=2>null</B></FONT></FONT><FONT size=2><FONT 
face=Arial>)</FONT></DIV>
<DIV align=left><FONT face=Arial>{</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"invalid FactHandler 
List"</FONT></FONT><FONT size=2><FONT face=Arial>);</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>return</FONT></B></FONT><FONT size=2><FONT face=Arial>;</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"size of fact 
handles..:"</FONT><FONT size=2>+</FONT><FONT color=#0000c0 
size=2>factHandles</FONT></FONT><FONT size=2><FONT 
face=Arial>.size());</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>while</FONT></B></FONT><FONT size=2><FONT 
face=Arial>(itr.hasNext())</FONT></DIV>
<DIV align=left><FONT face=Arial>{</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>try</FONT></B></FONT><FONT size=2><FONT face=Arial>{</FONT></DIV>
<DIV align=left><FONT face=Arial>FactHandle fh = 
(FactHandle)itr.next();</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>if</FONT></B></FONT><FONT face=Arial><FONT size=2>(fh == 
</FONT><B><FONT color=#7f0055 size=2>null</B></FONT></FONT><FONT size=2><FONT 
face=Arial>)</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"Here object is null, Cannot 
be retracted"</FONT></FONT><FONT size=2><FONT face=Arial>);</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>else</FONT></DIV></B></FONT><FONT size=2>
<DIV align=left><FONT face=Arial>{</FONT></DIV>
<DIV align=left></FONT><FONT face=Arial color=#0000c0 size=2>wm</FONT><FONT 
size=2><FONT face=Arial>.retractObject(fh);</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"Retracted object : 
"</FONT></FONT><FONT size=2><FONT face=Arial>+ fh);</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></FONT><B><FONT color=#7f0055 
size=2><FONT face=Arial>catch</FONT></B></FONT><FONT size=2><FONT face=Arial> 
(FactException e){</FONT></DIV>
<DIV align=left><FONT face=Arial>e.printStackTrace();</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>return</FONT></B></FONT><FONT size=2><FONT face=Arial>;</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>public</FONT></B></FONT><FONT face=Arial><FONT size=2> 
</FONT><B><FONT color=#7f0055 size=2>static</B></FONT></FONT><FONT 
face=Arial><FONT size=2> </FONT><B><FONT color=#7f0055 
size=2>void</B></FONT></FONT><FONT size=2><FONT face=Arial> main(String[] 
args){</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial>TestEvents3 te = </FONT></FONT><B><FONT 
color=#7f0055 size=2><FONT face=Arial>new</FONT></B></FONT><FONT size=2><FONT 
face=Arial> TestEvents3();</FONT></DIV>
<DIV align=left><FONT face=Arial></FONT>&nbsp;</DIV>
<DIV align=left></FONT><B><FONT color=#7f0055 size=2><FONT 
face=Arial>try</FONT></B></FONT><FONT size=2><FONT face=Arial>{</FONT></DIV>
<DIV align=left><FONT face=Arial>te.readRule(</FONT></FONT><FONT face=Arial 
color=#2a00ff size=2>"/AlarmSuppression.drl"</FONT><FONT size=2><FONT 
face=Arial>);</FONT></DIV>
<DIV align=left><FONT face=Arial>}</FONT></FONT><B><FONT color=#7f0055 
size=2><FONT face=Arial>catch</FONT></B></FONT><FONT size=2><FONT 
face=Arial>(Exception ex){</FONT></DIV>
<DIV align=left><FONT face=Arial>System.</FONT></FONT><I><FONT color=#0000c0 
size=2><FONT face=Arial>out</FONT></I></FONT><FONT face=Arial><FONT 
size=2>.println(</FONT><FONT color=#2a00ff size=2>"Caught Exception"</FONT><FONT 
size=2> +ex);</FONT></FONT></DIV>
<DIV align=left><FONT face=Arial size=2>ex.printStackTrace();}</FONT></DIV>
<DIV align=left><FONT face=Arial size=2>}</FONT></DIV>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV align=left><FONT face=Arial size=2>}</FONT></DIV>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV align=left><SPAN class=479580213-22022007><FONT face=Arial 
size=2>Thanks,</FONT></SPAN></DIV>
<DIV align=left><SPAN class=479580213-22022007><FONT face=Arial 
size=2>RameshReddy,</FONT></SPAN></DIV>
<DIV align=left><SPAN class=479580213-22022007><SPAN 
class=008332613-22022007><FONT face=Arial 
size=2>Trainee,</FONT></SPAN></SPAN></DIV>
<DIV align=left><SPAN class=479580213-22022007><SPAN 
class=008332613-22022007><FONT face=Arial size=2>Motorola 
India.</FONT></SPAN></SPAN></DIV>
<DIV align=left><FONT size=2><FONT size=2><SPAN class=479580213-22022007><FONT 
face=Arial size=2></FONT></SPAN></FONT></FONT>&nbsp;</DIV>
<DIV align=left><FONT size=2><FONT face=Arial size=2></FONT></FONT>&nbsp;</DIV>
<DIV><FONT size=2><FONT 
face=Arial></FONT></SPAN></FONT></FONT>&nbsp;</DIV></FONT></DIV></BODY></HTML>