Constructor and Description |
---|
BasicTool() |
Modifier and Type | Method and Description |
---|---|
void |
addListener(ExceptionEventListener listener)
Add the exception listener.
|
void |
awake()
Start sensing.
|
Bot |
getBot()
Return the associated Bot instance.
|
java.util.List<ExceptionEventListener> |
getListeners() |
java.lang.String |
getName()
Return the name that identifies the sense.
|
Primitive |
getPrimitive()
Allows senses to be referenced by memory.
|
Network |
getShortTermMemory()
Return the short term memory.
|
void |
initialize(java.util.Map<java.lang.String,java.lang.Object> properties)
Initialize any configurable settings from the properties.
|
boolean |
isEnabled()
Return if the sense is enabled.
|
void |
log(java.lang.String message,
java.util.logging.Level level)
Log the message if the debug level is greater or equal to the level.
|
void |
log(java.lang.String message,
java.util.logging.Level level,
java.lang.Object... arguments)
Log the message if the debug level is greater or equal to the level.
|
void |
log(java.lang.Throwable error)
Log the exception.
|
void |
notifyExceptionListeners(java.lang.Exception exception) |
void |
pool()
Reset state when instance is pooled.
|
void |
removeListener(ExceptionEventListener listener) |
void |
setBot(Bot Bot)
Set the associated Bot instance.
|
void |
setIsEnabled(boolean isEnabled)
Allow the sense to disabled/enabled.
|
void |
setName(java.lang.String name)
Set the name that identifies the sense.
|
void |
shutdown()
Stop sensing.
|
java.lang.String |
toString() |
public boolean isEnabled()
public void setIsEnabled(boolean isEnabled)
setIsEnabled
in interface Tool
public java.lang.String getName()
public void setName(java.lang.String name)
public Network getShortTermMemory()
public void log(java.lang.String message, java.util.logging.Level level, java.lang.Object... arguments)
public void log(java.lang.String message, java.util.logging.Level level)
public void log(java.lang.Throwable error)
public Primitive getPrimitive()
Tool
getPrimitive
in interface Tool
public java.lang.String toString()
toString
in class java.lang.Object
public Bot getBot()
public void setBot(Bot Bot)
public void initialize(java.util.Map<java.lang.String,java.lang.Object> properties)
initialize
in interface Tool
public void notifyExceptionListeners(java.lang.Exception exception)
notifyExceptionListeners
in interface Tool
public java.util.List<ExceptionEventListener> getListeners()
public void addListener(ExceptionEventListener listener)
public void removeListener(ExceptionEventListener listener)