|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.memphis.ccrg.lida.framework.shared.activation.ActivatibleImpl
edu.memphis.ccrg.lida.actionselection.BehaviorImpl
public class BehaviorImpl
Basic implementation of Behavior
Field Summary |
---|
Fields inherited from interface edu.memphis.ccrg.lida.framework.shared.activation.Activatible |
---|
DEFAULT_ACTIVATIBLE_REMOVAL_THRESHOLD, DEFAULT_ACTIVATION |
Constructor Summary | |
---|---|
BehaviorImpl()
Default constructor |
|
BehaviorImpl(Action action)
|
Method Summary | |
---|---|
boolean |
addContextCondition(Node condition)
Adds the context condition. |
boolean |
addToAddingList(Node addResult)
Adds the to adding list. |
boolean |
addToDeletingList(Node deleteResult)
Adds the to deleting list. |
boolean |
containsAddingItem(Node addItem)
Contains adding item. |
boolean |
containsContextCondition(Node contextCondition)
Contains context condition. |
boolean |
containsDeletingItem(Node deleteItem)
Contains deleting item. |
void |
deactivateAllContextConditions()
deactivates all context conditions. |
void |
deactiveContextCondition(Node condition)
Deactive context condition. |
void |
decay(long ticks)
decay the current activation using the decay strategy. |
boolean |
equals(java.lang.Object o)
|
Action |
getAction()
Gets action. |
NodeStructure |
getAddingList()
Gets adding list. |
double |
getAddingListCount()
Gets adding list count. |
NodeStructure |
getContext()
Gets context |
java.util.Collection<Node> |
getContextNodes()
Gets context nodes. |
java.lang.String |
getContextNodeType()
Gets context node type. |
int |
getContextSize()
Gets context size. |
NodeStructure |
getDeletingList()
Gets deleting list. |
double |
getDeletingListCount()
Gets deleting list count. |
Scheme |
getGeneratingScheme()
Gets generating scheme. |
long |
getId()
Gets id. |
java.lang.String |
getLabel()
Gets label. |
double |
getResultSize()
Gets result size. |
int |
getUnsatisfiedContextCount()
Gets unsatisfied context count. |
int |
hashCode()
|
boolean |
isAllContextConditionsSatisfied()
Returns true if all context conditions are satisfied. |
boolean |
isContextConditionSatisfied(Node prop)
Returns true if supplied condition is satisfied. |
void |
setAction(Action action)
Sets action |
void |
setContextNodeType(java.lang.String nodeType)
Sets context node type. |
void |
setGeneratingScheme(Scheme s)
Sets generating scheme. |
void |
setLabel(java.lang.String label)
Sets label. |
java.lang.String |
toString()
|
void |
updateAddingCondition(Node broadcastNode)
Update adding condition. |
void |
updateContextCondition(Node broadcastCondition)
marks supplied condition as present. |
void |
updateDeletingCondition(Node broadcastNode)
Update deleting condition. |
Methods inherited from class edu.memphis.ccrg.lida.framework.shared.activation.ActivatibleImpl |
---|
excite, getActivatibleRemovalThreshold, getActivation, getDecayStrategy, getExciteStrategy, getTotalActivation, isRemovable, setActivatibleRemovalThreshold, setActivation, setDecayStrategy, setExciteStrategy |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface edu.memphis.ccrg.lida.framework.shared.activation.Activatible |
---|
excite, getActivatibleRemovalThreshold, getActivation, getDecayStrategy, getExciteStrategy, getTotalActivation, isRemovable, setActivatibleRemovalThreshold, setActivation, setDecayStrategy, setExciteStrategy |
Constructor Detail |
---|
public BehaviorImpl()
public BehaviorImpl(Action action)
action
- Action
Method Detail |
---|
public void deactivateAllContextConditions()
Behavior
deactivateAllContextConditions
in interface Behavior
public void setAction(Action action)
Behavior
setAction
in interface Behavior
action
- Action
this behavior containspublic boolean isContextConditionSatisfied(Node prop)
Behavior
isContextConditionSatisfied
in interface Behavior
prop
- Node
public boolean isAllContextConditionsSatisfied()
Behavior
isAllContextConditionsSatisfied
in interface Behavior
public void updateContextCondition(Node broadcastCondition)
Behavior
updateContextCondition
in interface Behavior
broadcastCondition
- the conditionpublic void updateAddingCondition(Node broadcastNode)
Behavior
updateAddingCondition
in interface Behavior
broadcastNode
- the broadcast nodepublic void updateDeletingCondition(Node broadcastNode)
Behavior
updateDeletingCondition
in interface Behavior
broadcastNode
- the broadcast nodepublic void deactiveContextCondition(Node condition)
Behavior
deactiveContextCondition
in interface Behavior
condition
- the conditionpublic boolean addContextCondition(Node condition)
Behavior
addContextCondition
in interface Behavior
condition
- the condition
public boolean addToAddingList(Node addResult)
Behavior
addToAddingList
in interface Behavior
addResult
- the condition
public boolean addToDeletingList(Node deleteResult)
Behavior
addToDeletingList
in interface Behavior
deleteResult
- the delete condition
public java.util.Collection<Node> getContextNodes()
Behavior
getContextNodes
in interface Behavior
public NodeStructure getAddingList()
Behavior
getAddingList
in interface Behavior
public NodeStructure getDeletingList()
Behavior
getDeletingList
in interface Behavior
public int getContextSize()
Behavior
getContextSize
in interface Behavior
public double getAddingListCount()
Behavior
getAddingListCount
in interface Behavior
public double getDeletingListCount()
Behavior
getDeletingListCount
in interface Behavior
public Action getAction()
Behavior
getAction
in interface Behavior
Action
this behavior containspublic long getId()
Behavior
getId
in interface Behavior
public java.lang.String getLabel()
Behavior
getLabel
in interface Behavior
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public void decay(long ticks)
Activatible
decay
in interface Activatible
decay
in class ActivatibleImpl
ticks
- the number of ticks to decaypublic void setContextNodeType(java.lang.String nodeType)
Behavior
setContextNodeType
in interface Behavior
nodeType
- the new context node typepublic java.lang.String getContextNodeType()
Behavior
getContextNodeType
in interface Behavior
public boolean containsContextCondition(Node contextCondition)
Behavior
containsContextCondition
in interface Behavior
contextCondition
- the common node
public boolean containsAddingItem(Node addItem)
Behavior
containsAddingItem
in interface Behavior
addItem
- the common node
public boolean containsDeletingItem(Node deleteItem)
Behavior
containsDeletingItem
in interface Behavior
deleteItem
- the common node
public void setLabel(java.lang.String label)
Behavior
setLabel
in interface Behavior
label
- the new labelpublic Scheme getGeneratingScheme()
Behavior
getGeneratingScheme
in interface Behavior
public void setGeneratingScheme(Scheme s)
Behavior
setGeneratingScheme
in interface Behavior
s
- the new generating schemepublic double getResultSize()
Behavior
getResultSize
in interface Behavior
public int getUnsatisfiedContextCount()
Behavior
getUnsatisfiedContextCount
in interface Behavior
public java.lang.String toString()
toString
in class java.lang.Object
public NodeStructure getContext()
Behavior
getContext
in interface Behavior
NodeStructure
that is the context
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |