Drools :: Core 6.0.0.Beta5

org.drools.core.common
Class ScheduledAgendaItem

java.lang.Object
  extended by org.drools.core.common.ScheduledAgendaItem
All Implemented Interfaces:
Serializable, AgendaItem, Activation, Entry<ScheduledAgendaItem>, LinkedListNode<ScheduledAgendaItem>, org.kie.api.runtime.rule.Match

public class ScheduledAgendaItem
extends Object
implements AgendaItem, LinkedListNode<ScheduledAgendaItem>

See Also:
Serialized Form

Constructor Summary
ScheduledAgendaItem(AgendaItem agendaItem, InternalAgenda agenda)
           
 
Method Summary
 void addBlocked(LogicalDependency dep)
           
 void addLogicalDependency(LogicalDependency node)
           
 void cancel()
           
 void dequeue()
           
 ActivationGroupNode getActivationGroupNode()
           
 ActivationNode getActivationNode()
           
 long getActivationNumber()
          Each PropgationContext is assigned an id from a counter for the WorkingMemory action it represents.
 org.kie.internal.event.rule.ActivationUnMatchListener getActivationUnMatchListener()
           
 InternalAgendaGroup getAgendaGroup()
           
 LinkedList<LogicalDependency> getBlocked()
           
 LinkedList<LinkedListEntry<LogicalDependency>> getBlockers()
           
 Consequence getConsequence()
           
 List<String> getDeclarationIds()
           
 Object getDeclarationValue(String variableName)
           
 InternalFactHandle getFactHandle()
           
 List<FactHandle> getFactHandles()
           
 JobHandle getJobHandle()
           
 LinkedList<LogicalDependency> getLogicalDependencies()
           
 ScheduledAgendaItem getNext()
           
 List<Object> getObjects()
           
 ScheduledAgendaItem getPrevious()
          Returns the previous node
 PropagationContext getPropagationContext()
          Retrieve the PropagationContext for the Activation
 int getQueueIndex()
           
 Rule getRule()
           
 RuleAgendaItem getRuleAgendaItem()
           
 int getSalience()
           
 GroupElement getSubRule()
          Retrieve the subrule that was activated.
 TerminalNode getTerminalNode()
           
 LeftTuple getTuple()
          Retrieve the Tuple that was activated.
 boolean isCanceled()
           
 boolean isEnqueued()
           
 boolean isMatched()
           
 boolean isQueued()
           
 boolean isRuleAgendaItem()
           
 void remove()
          Cancel the Activation by removing it from the Agenda.
 void removeAllBlockersAndBlocked(DefaultAgenda agenda)
           
 void removeBlocked(LogicalDependency dep)
           
 void setActivationGroupNode(ActivationGroupNode activationNode)
           
 void setActivationNode(ActivationNode activationNode)
           
 void setActivationUnMatchListener(org.kie.internal.event.rule.ActivationUnMatchListener activationUnMatchListener)
           
 void setBlocked(LinkedList<LogicalDependency> justified)
           
 void setEnqueued(boolean enqueued)
           
 void setFactHandle(InternalFactHandle factHandle)
           
 void setJobHandle(JobHandle jobHandle)
           
 void setLogicalDependencies(LinkedList<LogicalDependency> justified)
           
 void setMatched(boolean matched)
           
 void setNext(ScheduledAgendaItem next)
           
 void setPrevious(ScheduledAgendaItem previous)
          Sets the previous node
 void setPropagationContext(PropagationContext context)
           
 void setQueued(boolean queued)
           
 void setQueueIndex(int index)
           
 void setSalience(int salience)
           
 String toExternalForm()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.drools.core.common.AgendaItem
equals, hashCode
 

Constructor Detail

ScheduledAgendaItem

public ScheduledAgendaItem(AgendaItem agendaItem,
                           InternalAgenda agenda)
Method Detail

getPropagationContext

public PropagationContext getPropagationContext()
Description copied from interface: Activation
Retrieve the PropagationContext for the Activation

Specified by:
getPropagationContext in interface AgendaItem
Specified by:
getPropagationContext in interface Activation
Returns:
The propagation context

setPropagationContext

public void setPropagationContext(PropagationContext context)
Specified by:
setPropagationContext in interface AgendaItem

isMatched

public boolean isMatched()
Specified by:
isMatched in interface AgendaItem
Specified by:
isMatched in interface Activation

setMatched

public void setMatched(boolean matched)
Specified by:
setMatched in interface AgendaItem
Specified by:
setMatched in interface Activation

getTerminalNode

public TerminalNode getTerminalNode()
Specified by:
getTerminalNode in interface AgendaItem

getSalience

public int getSalience()
Specified by:
getSalience in interface AgendaItem
Specified by:
getSalience in interface Activation

setSalience

public void setSalience(int salience)
Specified by:
setSalience in interface AgendaItem

toExternalForm

public String toExternalForm()
Specified by:
toExternalForm in interface AgendaItem

getBlocked

public LinkedList<LogicalDependency> getBlocked()
Specified by:
getBlocked in interface AgendaItem
Specified by:
getBlocked in interface Activation

setBlocked

public void setBlocked(LinkedList<LogicalDependency> justified)
Specified by:
setBlocked in interface AgendaItem
Specified by:
setBlocked in interface Activation

getFactHandle

public InternalFactHandle getFactHandle()
Specified by:
getFactHandle in interface AgendaItem
Specified by:
getFactHandle in interface Activation

setFactHandle

public void setFactHandle(InternalFactHandle factHandle)
Specified by:
setFactHandle in interface AgendaItem

getActivationGroupNode

public ActivationGroupNode getActivationGroupNode()
Specified by:
getActivationGroupNode in interface AgendaItem
Specified by:
getActivationGroupNode in interface Activation

setActivationGroupNode

public void setActivationGroupNode(ActivationGroupNode activationNode)
Specified by:
setActivationGroupNode in interface AgendaItem
Specified by:
setActivationGroupNode in interface Activation

getConsequence

public Consequence getConsequence()
Specified by:
getConsequence in interface AgendaItem
Specified by:
getConsequence in interface Activation

getActivationUnMatchListener

public org.kie.internal.event.rule.ActivationUnMatchListener getActivationUnMatchListener()
Specified by:
getActivationUnMatchListener in interface AgendaItem

setActivationUnMatchListener

public void setActivationUnMatchListener(org.kie.internal.event.rule.ActivationUnMatchListener activationUnMatchListener)
Specified by:
setActivationUnMatchListener in interface AgendaItem

getRule

public Rule getRule()
Specified by:
getRule in interface AgendaItem
Specified by:
getRule in interface Activation
Specified by:
getRule in interface org.kie.api.runtime.rule.Match
Returns:
The rule that was activated.

getAgendaGroup

public InternalAgendaGroup getAgendaGroup()
Specified by:
getAgendaGroup in interface AgendaItem
Specified by:
getAgendaGroup in interface Activation

getActivationNumber

public long getActivationNumber()
Description copied from interface: Activation
Each PropgationContext is assigned an id from a counter for the WorkingMemory action it represents. All Activations return this id as the ActivationNumber, thus all Activations created from the same PropgationContext will return the same long for this method.

Specified by:
getActivationNumber in interface AgendaItem
Specified by:
getActivationNumber in interface Activation
Returns:
The activation number

removeBlocked

public void removeBlocked(LogicalDependency dep)
Specified by:
removeBlocked in interface AgendaItem

addBlocked

public void addBlocked(LogicalDependency dep)
Specified by:
addBlocked in interface AgendaItem
Specified by:
addBlocked in interface Activation

dequeue

public void dequeue()
Specified by:
dequeue in interface AgendaItem
Specified by:
dequeue in interface Activation

getQueueIndex

public int getQueueIndex()
Specified by:
getQueueIndex in interface AgendaItem
Specified by:
getQueueIndex in interface Activation

setQueueIndex

public void setQueueIndex(int index)
Specified by:
setQueueIndex in interface AgendaItem
Specified by:
setQueueIndex in interface Activation

isQueued

public boolean isQueued()
Specified by:
isQueued in interface AgendaItem
Specified by:
isQueued in interface Activation

setQueued

public void setQueued(boolean queued)
Specified by:
setQueued in interface AgendaItem
Specified by:
setQueued in interface Activation

addLogicalDependency

public void addLogicalDependency(LogicalDependency node)
Specified by:
addLogicalDependency in interface AgendaItem
Specified by:
addLogicalDependency in interface Activation

getBlockers

public LinkedList<LinkedListEntry<LogicalDependency>> getBlockers()
Specified by:
getBlockers in interface AgendaItem
Specified by:
getBlockers in interface Activation

getDeclarationValue

public Object getDeclarationValue(String variableName)
Specified by:
getDeclarationValue in interface AgendaItem
Specified by:
getDeclarationValue in interface org.kie.api.runtime.rule.Match

getRuleAgendaItem

public RuleAgendaItem getRuleAgendaItem()
Specified by:
getRuleAgendaItem in interface AgendaItem

getTuple

public LeftTuple getTuple()
Description copied from interface: Activation
Retrieve the Tuple that was activated.

Specified by:
getTuple in interface AgendaItem
Specified by:
getTuple in interface Activation
Returns:
The tuple.

getDeclarationIds

public List<String> getDeclarationIds()
Specified by:
getDeclarationIds in interface AgendaItem
Specified by:
getDeclarationIds in interface org.kie.api.runtime.rule.Match

cancel

public void cancel()
Specified by:
cancel in interface AgendaItem

getActivationNode

public ActivationNode getActivationNode()
Specified by:
getActivationNode in interface AgendaItem
Specified by:
getActivationNode in interface Activation

setActivationNode

public void setActivationNode(ActivationNode activationNode)
Specified by:
setActivationNode in interface AgendaItem
Specified by:
setActivationNode in interface Activation

getSubRule

public GroupElement getSubRule()
Description copied from interface: Activation
Retrieve the subrule that was activated.

Specified by:
getSubRule in interface AgendaItem
Specified by:
getSubRule in interface Activation
Returns:

removeAllBlockersAndBlocked

public void removeAllBlockersAndBlocked(DefaultAgenda agenda)
Specified by:
removeAllBlockersAndBlocked in interface AgendaItem

isCanceled

public boolean isCanceled()
Specified by:
isCanceled in interface AgendaItem

getObjects

public List<Object> getObjects()
Specified by:
getObjects in interface AgendaItem
Specified by:
getObjects in interface org.kie.api.runtime.rule.Match

isRuleAgendaItem

public boolean isRuleAgendaItem()
Specified by:
isRuleAgendaItem in interface AgendaItem
Specified by:
isRuleAgendaItem in interface Activation

getLogicalDependencies

public LinkedList<LogicalDependency> getLogicalDependencies()
Specified by:
getLogicalDependencies in interface AgendaItem
Specified by:
getLogicalDependencies in interface Activation

setLogicalDependencies

public void setLogicalDependencies(LinkedList<LogicalDependency> justified)
Specified by:
setLogicalDependencies in interface AgendaItem
Specified by:
setLogicalDependencies in interface Activation

getFactHandles

public List<FactHandle> getFactHandles()
Specified by:
getFactHandles in interface AgendaItem
Specified by:
getFactHandles in interface org.kie.api.runtime.rule.Match

getNext

public ScheduledAgendaItem getNext()
Specified by:
getNext in interface Entry<ScheduledAgendaItem>

setNext

public void setNext(ScheduledAgendaItem next)
Specified by:
setNext in interface Entry<ScheduledAgendaItem>

getPrevious

public ScheduledAgendaItem getPrevious()
Description copied from interface: LinkedListNode
Returns the previous node

Specified by:
getPrevious in interface LinkedListNode<ScheduledAgendaItem>
Returns:
The previous LinkedListNode

setPrevious

public void setPrevious(ScheduledAgendaItem previous)
Description copied from interface: LinkedListNode
Sets the previous node

Specified by:
setPrevious in interface LinkedListNode<ScheduledAgendaItem>
Parameters:
previous - The previous LinkedListNode

remove

public void remove()
Description copied from interface: Activation
Cancel the Activation by removing it from the Agenda.

Specified by:
remove in interface AgendaItem
Specified by:
remove in interface Activation

getJobHandle

public JobHandle getJobHandle()

setJobHandle

public void setJobHandle(JobHandle jobHandle)

toString

public String toString()
Specified by:
toString in interface AgendaItem
Overrides:
toString in class Object

isEnqueued

public boolean isEnqueued()

setEnqueued

public void setEnqueued(boolean enqueued)

Drools :: Core 6.0.0.Beta5

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