org.jactr.modules.pm.aural
Class AbstractAuralModule
java.lang.Object
org.jactr.core.module.AbstractModule
org.jactr.core.module.asynch.AbstractAsynchronousModule
org.jactr.modules.pm.AbstractPerceptualModule
org.jactr.modules.pm.aural.AbstractAuralModule
- All Implemented Interfaces:
- IAsynchronousModule, IModule, IInitializable, IInstallable, IParameterized, IAuralModule, IPerceptualMemoryModule, IPerceptualModule
- Direct Known Subclasses:
- DefaultAuralModule6
public abstract class AbstractAuralModule
- extends AbstractPerceptualModule
- implements IAuralModule, IParameterized
abstract implementation of the aural module that takes care of most of the
details. It handles parameter, FINST management, and buffer stuffing. It is
up to the extenders to deal with the actual attending, search, buffer and
memory creation.
- Author:
- developer
| Fields inherited from interface org.jactr.modules.pm.aural.IAuralModule |
ATTENDED_STATUS_SLOT, AUDIO_EVENT_CHUNK_TYPE, AURAL_BUFFER, AURAL_LOCATION_BUFFER, AZIMUTH_SLOT, CLEAR_CHUNK_TYPE, CONTENT_SLOT, DIGIT_CHUNK_TYPE, DURATION_SLOT, ELEVATION_SLOT, EVENT_SLOT, EXTERNAL_CHUNK, INTERNAL_CHUNK, KIND_SLOT, LOCATION_SLOT, OFFSET_SLOT, ONSET_SLOT, PITCH_SLOT, SOUND_CHUNK_TYPE, SPEECH_CHUNK_TYPE, TONE_CHUNK_TYPE, WORD_CHUNK_TYPE |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ENABLE_BUFFER_STUFF_PARAM
public static final java.lang.String ENABLE_BUFFER_STUFF_PARAM
- See Also:
- Constant Field Values
AURAL_DECAY_TIME_PARAM
public static final java.lang.String AURAL_DECAY_TIME_PARAM
- See Also:
- Constant Field Values
ENCODING_TIME_EQUATION_PARAM
public static final java.lang.String ENCODING_TIME_EQUATION_PARAM
- See Also:
- Constant Field Values
AbstractAuralModule
public AbstractAuralModule()
- Parameters:
name -
addListener
public void addListener(IAuralModuleListener listener,
java.util.concurrent.Executor executor)
- Specified by:
addListener in interface IAuralModule
removeListener
public void removeListener(IAuralModuleListener listener)
- Specified by:
removeListener in interface IAuralModule
hasListeners
public boolean hasListeners()
- Specified by:
hasListeners in interface IAuralModule
dispatch
public void dispatch(AuralModuleEvent event)
- Specified by:
dispatch in interface IAuralModule
initialize
public void initialize()
- Description copied from interface:
IModule
- this will be called after all the modules have been installed permitting
the module to attach listeners to other modules. if you want to get access
to chunks,types, or productions before the model runs, attach a model
listener and do that during the modelStarted call
- Specified by:
initialize in interface IModule- Specified by:
initialize in interface IInitializable- Overrides:
initialize in class AbstractPerceptualModule
- See Also:
AbstractModule.initialize()
dispose
public void dispose()
- Description copied from interface:
IModule
- release any resources. this should only be called by the model during its
own dispose method (assuming that this module is still installed) and
should not result in the propogation of ANY events. The module should
dispose of all its resources, including buffers
- Specified by:
dispose in interface IModule- Overrides:
dispose in class AbstractPerceptualModule
isBufferStuffEnabled
public boolean isBufferStuffEnabled()
getAuralMemory
public IAuralMemory getAuralMemory()
- Description copied from interface:
IAuralModule
- return the backing aural memory. this is only valid after the module has
been connected to CR.
- Specified by:
getAuralMemory in interface IAuralModule
- Returns:
getPerceptualMemory
public IPerceptualMemory getPerceptualMemory()
- Specified by:
getPerceptualMemory in interface IPerceptualMemoryModule
getAuralActivationBuffer
public IAuralActivationBuffer getAuralActivationBuffer()
- Specified by:
getAuralActivationBuffer in interface IAuralModule
- See Also:
IAuralModule.getAuralActivationBuffer()
getAuralLocationBuffer
public IAuralLocationBuffer getAuralLocationBuffer()
- Specified by:
getAuralLocationBuffer in interface IAuralModule
- See Also:
IAuralModule.getAuralLocationBuffer()
getEncodingTimeEquation
public IAuralEncodingTimeEquation getEncodingTimeEquation()
- Specified by:
getEncodingTimeEquation in interface IAuralModule
getClearChunkType
public IChunkType getClearChunkType()
- Specified by:
getClearChunkType in interface IAuralModule
getSoundChunkType
public IChunkType getSoundChunkType()
- Specified by:
getSoundChunkType in interface IAuralModule
getAudioEventChunkType
public IChunkType getAudioEventChunkType()
- Specified by:
getAudioEventChunkType in interface IAuralModule
getLowestChunk
public IChunk getLowestChunk()
- Specified by:
getLowestChunk in interface IAuralModule
getHighestChunk
public IChunk getHighestChunk()
- Specified by:
getHighestChunk in interface IAuralModule
getInternalChunk
public IChunk getInternalChunk()
- Specified by:
getInternalChunk in interface IAuralModule
getExternalChunk
public IChunk getExternalChunk()
- Specified by:
getExternalChunk in interface IAuralModule
getRecodeTime
public double getRecodeTime(IChunkType chunkType)
setRecodeTime
public void setRecodeTime(IChunkType chunkType,
double time)
getAuralDecayTime
public double getAuralDecayTime()
- Description copied from interface:
IAuralModule
- how long does a sound take to decay out of the audicon
- Specified by:
getAuralDecayTime in interface IAuralModule
- Returns:
- See Also:
IAuralModule.getAuralDecayTime()
setAuralDecayTime
public void setAuralDecayTime(double time)
- Specified by:
setAuralDecayTime in interface IAuralModule
- See Also:
IAuralModule.setAuralDecayTime(double)
getSetableParameters
public java.util.Collection<java.lang.String> getSetableParameters()
- Description copied from interface:
IParameterized
- Return list of all parameters that can be set.
- Specified by:
getSetableParameters in interface IParameterized- Overrides:
getSetableParameters in class AbstractAsynchronousModule
- Returns:
- The setableParameters value
setParameter
public void setParameter(java.lang.String key,
java.lang.String value)
- Description copied from interface:
IParameterized
- Set the named parameter
- Specified by:
setParameter in interface IParameterized- Overrides:
setParameter in class AbstractAsynchronousModule
getParameter
public java.lang.String getParameter(java.lang.String key)
- Description copied from interface:
IParameterized
- return parameter value - null if not defined.
- Specified by:
getParameter in interface IParameterized- Overrides:
getParameter in class AbstractAsynchronousModule
- Parameters:
key - Description of the Parameter
- Returns:
- The parameter value