Drools :: Core 6.0.0.Beta5

org.drools.core.phreak
Class AddRemoveRule

java.lang.Object
  extended by org.drools.core.phreak.AddRemoveRule

public class AddRemoveRule
extends Object


Constructor Summary
AddRemoveRule()
           
 
Method Summary
static void addRule(TerminalNode tn, InternalWorkingMemory[] wms)
           
static void collectRtnPathMemories(LeftTupleSource lt, InternalWorkingMemory wm, List<PathMemory> pathMems, TerminalNode excludeTerminalNode)
           
static void correctSegmentMemoryAfterSplitOnAdd(SegmentMemory sm)
           
static void correctSegmentMemoryAfterSplitOnRemove(SegmentMemory sm)
           
static void deleteFacts(LeftTupleSink startNode, InternalWorkingMemory wm)
           
static LeftTupleSource getNetworkSplitPoint(TerminalNode tn)
           
static int getSegmentPos(LeftTupleSource lts, Rule removingRule)
           
static void mergeSegment(SegmentMemory sm1, SegmentMemory sm2)
           
static void processLeftTuples(LeftTupleSource node, LeftTupleSink peerNode, SegmentMemory smem, InternalWorkingMemory wm, boolean insert)
          Populates the SegmentMemory with staged LeftTuples.
static void removeRule(TerminalNode tn, InternalWorkingMemory[] wms)
           
static SegmentMemory splitSegment(SegmentMemory sm1, LeftTupleSource splitNode)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AddRemoveRule

public AddRemoveRule()
Method Detail

addRule

public static void addRule(TerminalNode tn,
                           InternalWorkingMemory[] wms)

removeRule

public static void removeRule(TerminalNode tn,
                              InternalWorkingMemory[] wms)

correctSegmentMemoryAfterSplitOnAdd

public static void correctSegmentMemoryAfterSplitOnAdd(SegmentMemory sm)

correctSegmentMemoryAfterSplitOnRemove

public static void correctSegmentMemoryAfterSplitOnRemove(SegmentMemory sm)

getSegmentPos

public static int getSegmentPos(LeftTupleSource lts,
                                Rule removingRule)

deleteFacts

public static void deleteFacts(LeftTupleSink startNode,
                               InternalWorkingMemory wm)

processLeftTuples

public static void processLeftTuples(LeftTupleSource node,
                                     LeftTupleSink peerNode,
                                     SegmentMemory smem,
                                     InternalWorkingMemory wm,
                                     boolean insert)
Populates the SegmentMemory with staged LeftTuples. If the parent is not a Beta or From node, it iterates up to find the first node with memory. If necessary It traverses to the LiaNode's ObjectTypeNode. It then iterates the LeftTuple chain, on a specific path to navigate down to where an existing LeftTuple is staged as delete. Or a new LeftTuple is created and staged as an insert.

Parameters:
node -
peerNode -
smem -
wm -
insert -

collectRtnPathMemories

public static void collectRtnPathMemories(LeftTupleSource lt,
                                          InternalWorkingMemory wm,
                                          List<PathMemory> pathMems,
                                          TerminalNode excludeTerminalNode)

getNetworkSplitPoint

public static LeftTupleSource getNetworkSplitPoint(TerminalNode tn)

splitSegment

public static SegmentMemory splitSegment(SegmentMemory sm1,
                                         LeftTupleSource splitNode)

mergeSegment

public static void mergeSegment(SegmentMemory sm1,
                                SegmentMemory sm2)

Drools :: Core 6.0.0.Beta5

Copyright © 2001-2013 JBoss by Red Hat. All Rights Reserved.