<div dir="ltr"><div>You could add an attribute on the Line object to mark it as processed or something when a match is found. You could then write another rule that looks for unprocessed lines and retracts them.</div>
<div> </div>
<div>dave<br><br></div>
<div class="gmail_quote">On Fri, Oct 17, 2008 at 2:56 PM, hare ram <span dir="ltr"><<a href="mailto:hare.bond@gmail.com">hare.bond@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<div dir="ltr">Hello all, <br><br>This is the set of rules i have<br><br>rule "IP Route File rule"<br> salience 2000<br> when<br> Line ( line matches "^.*\s+show\s+ip\s+route\s*$" )<br> Line ( line matches "^.*\s+dest\s+address\s*$ )<br>
file : FileFinder()<br> <br> then <br> file.setFileType("ip route file");<br> drools.halt();<br>end<br><br><br><br>All I am doing in rules is, I read each line from the given file, convert them into Line Objects and see if any of my<br>
rules matches. There are about 50 such rules, that will help me differentiate what kind of file is present in my input<br>directory.<br><br>The question I have , is there a way I can know if Line Object matched any of the rules ? If a Line Object is not matched by<br>
any of rules, I can just retract that object from the memory and prevent Out of Memory Exception if the file size is huge<br><br>Thanks<br>Shiva<br><br><br></div><br>_______________________________________________<br>rules-dev mailing list<br>
<a href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/rules-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br><br></blockquote>
</div><br></div>